in reply to .bat and perl mystery
t-cmd.pl:
and 'hello world.bat':#!/usr/bin/perl use strict; use warnings; $|++; my $cmd = 'hello world.bat'; my @cmd_args = qw/ testing testing 1 2 3 /; my $exit_code = system( $cmd, @cmd_args ); print 'exit code from ', $cmd, ' is ', $exit_code, $/;
does this work? system returns the exit code from the command. use backticks or qx// to get the program's STDOUT into a scalar or array.echo hello world! echo %1 %2 %3 %4 %5
~Particle *accelerates*
In Section
Seekers of Perl Wisdom