Edgewall Software
Modify

Opened 17 years ago

Last modified 12 years ago

#204 new enhancement

sh:exec: Output stdout and stderr to individual files

Reported by: staffan.spam@… Owned by: cmlenz
Priority: minor Milestone: 0.6.1
Component: Recipe commands Version:
Keywords: sh:exec Cc:
Operating System:

Description

It'd be nice there was a way to control the output of individual streams for the sh:exec recipe command. I.e.:

  • output stderr and stdout to different files.
  • output only one of them to file.

(If there already is a way to do this, it's not documented.)

Attachments (1)

stdout-stderr.diff (5.3 KB) - added by Olaf Meeuwissen <olaf@…> 15 years ago.
Split destination of stdout and stderr to separate files

Download all attachments as: .zip

Change History (4)

comment:1 Changed 17 years ago by staffan.spam@…

  • Type changed from defect to enhancement

comment:2 Changed 15 years ago by osimons

  • Milestone changed from 0.6 to 0.6.1

comment:3 Changed 15 years ago by Olaf Meeuwissen <olaf@…>

On both branches/0.6.x and trunk, the sh:exec and sh:pipe commands put stdout and stderr messages in the file specified via the command's output attribute. Note that stdout is logged at info and stderr at error priority.

Patching the output to file behaviour is pretty straightforward. The only problem is what should be done with stderr in the case the output attribute is specified. Currently, it ends up in the output file, which may or may not be desirable. My main concern here is with backwards compatiblity and I'm not sure what is preferred: keeping things the way they are or leaving stderr out of the output file.

I'll have a shot at making a patch (for the latter approach, which is what I prefer).

Changed 15 years ago by Olaf Meeuwissen <olaf@…>

Split destination of stdout and stderr to separate files

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain cmlenz.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.