]> git.donarmstrong.com Git - lib.git/commitdiff
add perl script template
authorDon Armstrong <don@donarmstrong.com>
Thu, 10 Aug 2006 08:02:01 +0000 (08:02 +0000)
committerDon Armstrong <don@donarmstrong.com>
Thu, 10 Aug 2006 08:02:01 +0000 (08:02 +0000)
templates/perl_script [new file with mode: 0755]

diff --git a/templates/perl_script b/templates/perl_script
new file mode 100755 (executable)
index 0000000..b4b08d9
--- /dev/null
@@ -0,0 +1,69 @@
+#! /usr/bin/perl
+# , and is released
+# under the terms of the GPL version 2, or any later version, at your
+# option. See the file README and COPYING for more information.
+# Copyright 2006 by Don Armstrong <don@donarmstrong.com>.
+# $Id$
+
+
+use warnings;
+use strict;
+
+use Getopt::Long;
+use Pod::Usage;
+
+=head1 NAME
+
+ - 
+
+=head1 SYNOPSIS
+
+ [options]
+
+ Options:
+  --debug, -d debugging level (Default 0)
+  --help, -h display this help
+  --man, -m display manual
+
+=head1 OPTIONS
+
+=over
+
+=item B<--debug, -d>
+
+Debug verbosity. (Default 0)
+
+=item B<--help, -h>
+
+Display brief useage information.
+
+=item B<--man, -m>
+
+Display this manual.
+
+=back
+
+=head1 EXAMPLES
+
+
+=cut
+
+
+use vars qw($DEBUG);
+
+my %options = (debug           => 0,
+              help            => 0,
+              man             => 0,
+              );
+
+GetOptions(\%options,'debug|d+','help|h|?','man|m');
+
+pod2usage() if $options{help};
+pod2usage({verbose=>2}) if $options{man};
+
+$DEBUG = $options{debug};
+
+
+
+
+__END__