Created
October 17, 2013 06:38
-
-
Save bessarabov/7020058 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
=encoding UTF-8 | |
=cut | |
=head1 DESCRIPTION | |
=cut | |
# common modules | |
use strict; | |
use warnings FATAL => 'all'; | |
use feature 'say'; | |
use utf8; | |
use open qw(:std :utf8); | |
use Data::Dumper; | |
use Carp; | |
use DhMakePerl::Config; | |
use Debian::AptContents; | |
# global vars | |
# subs | |
# main | |
sub main { | |
my $cfg = DhMakePerl::Config->new; | |
$cfg->parse_command_line_options; | |
$cfg->parse_config_file; | |
my $params = { | |
homedir => $cfg->home_dir, | |
dist => $cfg->dist, | |
sources => $cfg->sources_list, | |
verbose => $cfg->verbose, | |
contents_dir => $cfg->apt_contents_dir, | |
}; | |
say Dumper $params; | |
my $apt_c = Debian::AptContents->new( $params ); | |
my @data = $apt_c->cache; | |
say Dumper \@data; | |
say '#END'; | |
} | |
main(); | |
__END__ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment