in reply to Safe cross-platform command execution and capture of STDOUT & STDERR

The following redirection captures both STDOUT and STDIN and works equally well in DOS as in unix sh:
myprog.pl > myprog.log 2>&1
(tested on both platforms)

-M

Free your mind

  • Comment on Re: Safe cross-platform command execution and capture of STDOUT & STDERR
  • Download Code

Replies are listed 'Best First'.
Re^2: Safe cross-platform command execution and capture of STDOUT & STDERR
by Anonymous Monk on Nov 25, 2005 at 16:27 UTC
    hi, thanks for the suggestion - IPC::Run3 is perfect for what I need. Matt