>
>
> > Hi,
> > i am using the Getopt::Std package in my code.
> >
> >
> > use Getopt::Std;
> >
> > getopts('s:');
> >
> > $a = $opt_s
By the way, you don't really need to assign the $opt_x variables to a new
variable. $opt_s will be persistant, unless you run getopt again, which would
b
Put quotes around your arguments. Use single quotes if you are not doing
variable substitution, and double quotes if otherwise.
That is:
my_program.pl -s 'will[1]' "$will"
__
William Ampeh (x3939)
Federal Reserve Board
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For a
> Hi,
> i am using the Getopt::Std package in my code.
>
>
> use Getopt::Std;
>
> getopts('s:');
>
> $a = $opt_s
>
>
> this is how i run my program from command line "
>
> > my_program.pl -s pattern
>
> now if "pattern" is something like abcd[12] how do i
> make my program accept the in
>The perldoc for getopt::std states:
>Hash keys will be x (where x is the switch name) with key
>values the value of the argument or 1 if no argument is
>specified
This is true for getopt, but not getopts.
Getopts puts the parameter in the hash table (I am working on 5.005_03
built for aix )
per