D
david
Dear All,
I want to automize a process in perl.
In this process I have the following code
sub run_command {
my ($command) = @_;
print "$command\n";
system($command) == 0
or die "system $command failed: $? -- $!"
}
run_command('source init_file');
run_command('mycommand.pl -configfile config -exec ');
I get the following error
source init
Can't exec "source": No such file or directory at ..
system source init failed: -1 -- No such file or directory at ...
Can please someone help me to understand what i did wrong.
Best regards,
David
I want to automize a process in perl.
In this process I have the following code
sub run_command {
my ($command) = @_;
print "$command\n";
system($command) == 0
or die "system $command failed: $? -- $!"
}
run_command('source init_file');
run_command('mycommand.pl -configfile config -exec ');
I get the following error
source init
Can't exec "source": No such file or directory at ..
system source init failed: -1 -- No such file or directory at ...
Can please someone help me to understand what i did wrong.
Best regards,
David