in reply to how i capture a script error to a file ?
and Re^3: Capturing STDERR using IO::Handle for even more detailed examples.
It's documented in the perldocs, but can't remember where...
If you just want to redirect STDERR permanently for the lifetime of your Perl execution (beware of modperl !!!), this should do (and capture also all compilation errors)
BEGIN { close STDERR; open STDERR, ">>", "log.err"; }
Cheers Rolf
(addicted to the Perl Programming Language and ☆☆☆☆ :)
Je suis Charlie!
|
|---|