Skip to content
Browse files

pod2usage(-verbose=>1) for display OPTIONS

  • Loading branch information...
1 parent 5cac334 commit 9ce452cddf8d4656ee564e3d0669d0c0d5d1f8a1 @kazeburo kazeburo committed Apr 12, 2012
Showing with 9 additions and 6 deletions.
  1. +5 −4 orepan.pl
  2. +4 −2 orepan_index.pl
View
9 orepan.pl
@@ -23,12 +23,13 @@
my $pauseid = 'DUMMY';
GetOptions(
'p|pauseid=s' => sub { $pauseid = uc $_[1] },
- 'd|destination=s' => \my $destination
+ 'd|destination=s' => \my $destination,
+ 'h|help' => \my $help,
);
-pod2usage() unless $destination;
+pod2usage(-verbose=>1) unless $destination;
my ($pkg) = @ARGV;
-$pkg or pod2usage();
+$pkg or pod2usage(-verbose=>1);
my $tmp;
if ($pkg =~ m{^https?://}) {
@@ -74,7 +75,7 @@
=head1 NAME
-orepan.pl - DarkPAN manager
+orepan.pl - yet another CPAN mirror aka DarkPAN repository manager
=head1 SYNOPSIS
View
6 orepan_index.pl
@@ -22,8 +22,10 @@
GetOptions(
'r|repository=s' => \my $repository,
+ 'h|help' => \my $help,
);
-$repository or pod2usage();
+pod2usage(-verbose=>1) if $help;
+$repository or pod2usage(-verbose=>1);
$repository = dir($repository);
my $authordir = $repository->subdir('authors');
@@ -68,7 +70,7 @@ sub build_index {
=head1 NAME
-orepan_index.pl - DarkPAN index builder
+orepan_index.pl - yet another CPAN mirror aka DarkPAN index builder
=head1 SYNOPSIS

0 comments on commit 9ce452c

Please sign in to comment.
Something went wrong with that request. Please try again.