Missing something with Getopt::Std



Hello all,

I am trying to pass an arguement to a script I have but for some
reason Getopt::Std is not grabbing the value. I am also using
Config::IniFiles.

Is there something in the perldoc that I am missing about passing a
'0' (zero) from a command line perameter?

getopts('c:D:F:L:s:d:hV', \%opts);

$log_debug = ($opts{'L'} ? $opts{'L'} : $cfg->val('LOGGING',
'debug'));

if $cfg->val('LOGGING', 'debug') is set as 0 in the ini file, I can
pass a '1' as -L and the value is set as '1'. But if the value in the
ini file is set to 1, I cannot override it if I use -L 0 at the command
line.

Can anyone offer any suggestions about passing a '0' from the
commandline?

Thanks,
sunckell....

.



Relevant Pages

  • Re: Running an Executable from a JAVA API in LINUX
    ... > I'd just like to add that there is usually no reason to explicitly run ... > a shell at all in order to execute a child process. ... > command line arguments, you can write the command like this: ... I think he's just passing the parameters ...
    (comp.lang.java.programmer)
  • Accesing structures data (getting lengthy!)
    ... > assignment statement just won't stand out amongst all the other ... > meaningless dummy variables that you have to keep track of. ... > comparitively easy to pick out of a long, boring, command line history, ... > original, for some reason, wraps me up in knots. ...
    (comp.soft-sys.matlab)
  • Re: My Weekly Drash - Vayera
    ... you're asking what reason there might be for a ... >> literally speaking in one voice) and concluding that the law had never ... I have problem with that understanding, ... Because when the command _to him_ is to do ...
    (soc.culture.jewish.moderated)
  • Re: My Weekly Drash - Vayera
    ... >>> while I said I prefer to know the purpose of a law. ... > a reason. ... >> impart a reson to G-d's command. ... Moshe Schorr ...
    (soc.culture.jewish.moderated)
  • Re: 8.0 rc.d scripts less verbose?
    ... bug, but it's a bug that we've come to depend on. ... This late in the release cycle I'm comfortable adding a knob, ... pre-command routine or the command itself failed. ... whatever reason), it is nice to have an approximate idea which one ...
    (freebsd-stable)