turned into a dist
[scpubgit/System-Introspector.git] / dev-gather.pl
CommitLineData
90d22dbe 1#!/usr/bin/env perl
2use strictures 1;
3use lib qw( lib );
4use Data::Dump qw( pp );
5use Module::Runtime qw( use_module );
2f3044c6 6use Getopt::Long;
7use Data::YAML::Writer;
8
9GetOptions(
10 'yaml' => \(my $opt_yaml),
11);
90d22dbe 12
13my $intro = shift(@ARGV)
14 or die "Probe argument required\n";
15
2f3044c6 16my $data = use_module("System::Introspector::$intro")->new(@ARGV)->gather;
17if ($opt_yaml) {
18 my $writer = Data::YAML::Writer->new;
19 my $output = '';
20 $writer->write($data, \$output);
21 print $output;
22}
23else {
24 pp $data;
25}