in reply to (tye)Re: $ENV{PERL5SHELL}
in thread Security concern with sudo and system()
In the shell I use on Windows, command >& output redirects both stdout and stderr. I think something like what you show works too, but I'd have to look up the syntax details.
Who needs a shell? Do it all in Perl, and run external programs when you need them but don't rely on the shell to do anything for you. Instead do the same stuff in Perl! Like you point out, redirect the output. Also, do globbing, directory listing, etc. all in Perl and then just call the program. That's a path I've taken, because COMMAND.COM isn't worthy of the name shell and using a real shell is non-portable.
—John
|
|---|