[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] Perl command line
- Subject: [ale] Perl command line
- From: ivey at gweezlebur.com (Michael D. Ivey, RHCE)
- Date: Wed, 10 Jun 1998 11:21:21 -0400
On Wed, Jun 10, 1998 at 10:04:55AM -0500, Bob Kruger wrote:
> I am looking for some example Perl code for capturing a command line
> variable or variables.
GetOpt.pm is what you want. Take a look at the following snippetry:
#!/usr/bin/perl
use Getopt::Std;
getopts('n:');
if ($opt_n) { $number = $opt_n; }
try that. let me know if you need more information.
/mdi
--
Michael D. Ivey, RHCE | include(std_disclaimer.m4)dnl
-----------------------+-----------------------------------------------------
ivey at gweezlebur.com | "There's nothing wrong with sobriety in moderation."
http://gweezlebur.com | - John Ciardi