want to define the value of a var on the commandline is this possible ?It certainly is. See the -s option in the perlrun manpage. Here's a brief example
shell> cat > dash_s_switch.pl print "\$foo is $foo\n"; ^D shell> perl -s dash_s_switch.pl -foo="a string" $foo is a string
_________
broquaint
In reply to Re: defining variable values on the commandline
by broquaint
in thread defining variable values on the commandline
by fjonckers
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |