Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

dws (341)

dws
  (email not shown publicly)
http://www.davewsmith.com/

Journal of dws (341)

Monday April 07, 2003
06:27 PM

An Idiom I Like

[ #11503 ]
Either this is a new idiom, or just one I've missed until now, but

use Getopt::Long;
use Pod::Usage;
...
GetOptions(
   ...
) or pod2usage({verbose => 1, exitval => 1});
...
=head1 SYNOPSIS

  Switch a right-handed widget to the left.

  % switchlr widget [--verbose]

=head1 ARGUMENTS

  widget     the widget to switch

=head1 OPTIONS

  --verbose     be verbose about it

is nifty. Really nifty.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.