in reply to Pod::Usage issue.

I believe that Pod::Usage::pod2usage refers to pod2usage.PL which is a command line script; however, I think that you meant to use Pod::Usage, a part of the core. I used Pod::Usage for this script:

#!/sw/bin/perl use strict; use warnings; use Getopt::Long; use Pod::Usage; my $help = 0; GetOptions('help|?' => \$help) or pod2usage(2); pod2usage(1) if ($help); pod2usage(-exitval => 1, -verbose => 2); __END__ sample - Using GetOpt::Long and Pod::Usage =head1 SYNOPSIS sample [options] [file ...] Options: -help brief help message -man full documentation =head1 OPTIONS =over 8 =item B<-help> Print a brief help message and exits. =item B<-man> Prints the manual page and exits. =back =head1 DESCRIPTION B<This program> will read the given input file(s) and do something useful with the contents thereof. =cut

Replies are listed 'Best First'.
Re^2: Pod::Usage issue.
by Anonymous Monk on Sep 18, 2009 at 05:18 UTC
    I believe that Pod::Usage::pod2usage refers to pod2usage.PL which is a command line script; however, I think that you meant to use Pod::Usage, a part of the core. I used Pod::Usage for this script

    Why? That is complete nonsense.