Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: capturing stderr of echo piped to a file

by Crackers2 (Parson)
on Oct 28, 2014 at 22:10 UTC ( [id://1105381]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $command = "echo $writeline >> $file";
    my $output = `$command 2>&1`;
    
  2. or download this
    my $output = `$command echo $writeline >> $file 2>&1`;
    
  3. or download this
    my $output = `$command echo $writeline 2>&1 >> $file`;
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2024-03-28 17:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found