mlebel has asked for the wisdom of the Perl Monks concerning the following question:
Hello everyone,
I am wondering if there is a way to have multiple entries passed for a single option when launching a perl script. (the only post that I found this on was using getopt::long but i didn't quite understand the answer)
Here is an example of what I mean:
testmachine># ./testcode.pl -o entry1 entry2 or testmachine># ./testcode.pl -o entry1 -o entry2
If this is possible, what would be the code to handle this within a perl script?
If it is not possible, how could a situation like that be handled?
Any help is appreciated!
Thanks, Marc.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: multiple entries per option (Getopt)
by toolic (Bishop) on Jan 26, 2012 at 20:38 UTC | |
Re: multiple entries per option (Getopt)
by Perlbotics (Archbishop) on Jan 26, 2012 at 20:51 UTC | |
Re: multiple entries per option (Getopt)
by mlebel (Hermit) on Jan 27, 2012 at 02:41 UTC |
Back to
Seekers of Perl Wisdom