> I'm a perl newby.
me too:-)  Right list, I assume.
> I'm looking on taking a command line argument from
> STDIN and use it for input to a script that upgrades
> software. Any examples would be greatly appreciated.

@ARGV holds your  command line arguments.

call: 
scriptname.pl Universe  42 douglas 'Zappod Beblebrox' 

#! /usr/bin/perl
use strict;
use warnings;
print "You called me with ", scalar @ARGV, " Arguments.\n";
if (@ARGV) {
  print " Param to script: $_\n" foreach (@ARGV);
}

Notice that there is a nice wa of processing command line args with the 
getopt:: modules from CPAN.

Also take a look at perldoc perlvar for detailed info about @ARGV, ARGV and 
$ARGV.

Hope that helps, Wolf


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to