in reply to Re^2: Semicolon behaviour in system call
in thread Semicolon behaviour in system call
Do you get the same output from
C:\temp> pwd; pwd
as you do from
C:\temp> perl -e 'system("pwd; pwd");'
Do the same check for:
C:\temp> echo 1; echo 2; echo 3
From Perl, you may need to put each command in an array and use "system $_ for @cmds", e.g.
$ perl -e 'my @cmds = ("echo 1", "echo 2", "echo 3", "pwd", "pwd"); sy +stem $_ for @cmds' 1 2 3 /Users/ken/tmp /Users/ken/tmp
[I don't have Perl running on any MSWin platform, so I can't test this for you.]
-- Ken
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Semicolon behaviour in system call
by casual_prgmr (Initiate) on Mar 28, 2014 at 17:34 UTC | |
by ikegami (Patriarch) on Mar 28, 2014 at 17:42 UTC |