On Tue, Aug 23, 2011 at 5:53 PM, Emeka wrote:
> Hello All,
>
> Why shouldn't this work?
*snip*
> $result = GetOptions("age=i" => $age);
You should always try to explain the results you expect and what you
are getting instead. I had a hard time understanding what your problem
was just from reading
Hello All,
Why shouldn't this work?
use Getopt::Long;
#$debug = 0;
$result = GetOptions("age=i" => $age);
if ($age) {print "Input age is $age years"; }
Emeka
--
*Satajanus Nig. Ltd
*
deb wrote:
> Hi,
>
> Here's some (unfinished) code I am trying to use with Getopt::Std,
>
> #!/usr/local/bin/perl -w
> #
> use Getopt::Std;
> use diagnostics;
Ooops! You started your executable code without
use strict;
>
[snipped--No point in even scanning it without first letting the error-c
Deb wrote:
>
> Hi,
Hello,
> Here's some (unfinished) code I am trying to use with Getopt::Std,
>
> #!/usr/local/bin/perl -w
> #
> use Getopt::Std;
> use diagnostics;
> getopts('hn:');
>
> &usage if (defined $opt_h);
>
> sub usage { print <<"EOM"
> USAGE: $0 [-h] -n [EMAIL PROTECTED]
>
>
Hi,
Here's some (unfinished) code I am trying to use with Getopt::Std,
#!/usr/local/bin/perl -w
#
use Getopt::Std;
use diagnostics;
getopts('hn:');
&usage if (defined $opt_h);
sub usage { print <<"EOM"
USAGE: $0 [-h] -n [EMAIL PROTECTED]
-h This message
-n <[EMAIL PROTECTED]>
uffers from the problem, just in a different way).
For now, here's my short-term workaround for the AppConfig::Getopt module to fix the
problem (i.e. get it to play nice with the updated 2.32 Getopt::Long module). Edit the
AppConfig::Getopt module (AppConfig/Getopt.pm), updating the $linkage v
Karl Kaufman wrote:
>> For example:
>>
>> # test.pl -pagerdest [EMAIL PROTECTED]
is the above another typo? should it be:
test.pl --pagerdest [EMAIL PROTECTED]
you seem to have only one '-' in front of pagerdest?
Getopt::Long uses '--' not '-'
david
--
To unsubscribe, e-mail: [EMAIL PROT
PROTECTED]
Sent: Monday, August 26, 2002 5:12 PM
Subject: Re: Having problems with AppConfig::Getopt module
i have never used AppConfig::Getopt before...
Karl Kaufman wrote:
> For example:
>
> # test.pl -pagerdest [EMAIL PROTECTED]
>
> Should result in:
>
> %pager
i have never used AppConfig::Getopt before...
Karl Kaufman wrote:
> For example:
>
> # test.pl -pagerdest [EMAIL PROTECTED]
>
> Should result in:
>
> %pagerdest = {
> 'karl' => '[EMAIL PROTECTED]'
> };
but are you sure you mean that? it means it should assign a hash reference
to
Hello,
I'm trying to use the 'AppConfig::Getopt' module to parse my command-line arguments,
assigning the passed values to a hash. It's not working. And I need help.
For example:
# test.pl -pagerdest [EMAIL PROTECTED]
Should result in:
%pagerdest = {
'k
10 matches
Mail list logo