in reply to Re^2: Automating execution of shell scripts
in thread Automating execution of shell scripts
$text = @_;
This evaluates @_ in scalar context, returning the number of parameters instead of the actual value. Instead, use
my ($text) = @_;
Also,
if ($_ =~ ".*user_name.*"){
is better written as
if (/user_name/) {
|
|---|