Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: capturing stderr of echo piped to a file

by Crackers2 (Parson)
on Oct 28, 2014 at 22:10 UTC ( #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? | Other CB clients
Other Users?
Others meditating upon the Monastery: (6)
As of 2021-12-02 17:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    R or B?



    Results (23 votes). Check out past polls.

    Notices?