Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^2: Correct way to capture command output to a file in Perl.

by morgon (Deacon)
on May 02, 2013 at 15:02 UTC ( #1031766=note: print w/ replies, xml ) Need Help??


in reply to Re: Correct way to capture command output to a file in Perl.
in thread Correct way to capture command output to a file in Perl.

If you do it like that you would not use backticks but system() as you would not capture any output.

But I would not do it like that as in the error-case it is more difficult to determine what went wrong (e.g. the command you call may be able to run, but may not be able to write to the file).

  • Comment on Re^2: Correct way to capture command output to a file in Perl.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1031766]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (3)
As of 2016-06-28 08:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (352 votes). Check out past polls.