in reply to Using Getopt::Long to call subroutines
Despite what imp says, Getopt::Long works brilliantly for this.
# handle the no-args case: unless ( @ARGV ) { exit sub1(); } GetOptions( one => \&sub1, two => \&sub2, three => \&sub3, );
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Using Getopt::Long to call subroutines
by chinamox (Scribe) on Oct 22, 2006 at 05:18 UTC | |
by jdporter (Paladin) on Oct 22, 2006 at 13:32 UTC | |
by blazar (Canon) on Oct 22, 2006 at 16:25 UTC | |
|
Re^2: Using Getopt::Long to call subroutines
by imp (Priest) on Oct 22, 2006 at 04:44 UTC |