bug#21919: tee enhancement

2015-11-16 Thread Bernhard Voelker
On 11/14/2015 05:00 PM, Tim Shaw wrote: > What I would like to do is add a parameter to tee, "-2", that copies to > stderr in addition to stdout, just like "-" > copies to stdout twice. So the code becomes > echo big long complicated error message goes here | tee -2 > Simple, eh? Having an

bug#21919: tee enhancement

2015-11-16 Thread Pádraig Brady
On 14/11/15 16:00, Tim Shaw wrote: > If I am using stdout redirection of a shell block to capture some text I am > generating, errors need to go to stderr, but it would also be good if they > went into the generated output. For example > for i in files*; do > if there_is_an_error; then >

bug#21919: tee enhancement

2015-11-16 Thread Pádraig Brady
tag 21919 notabug close 21919 stop On 15/11/15 23:59, Pádraig Brady wrote: > On 14/11/15 16:00, Tim Shaw wrote: >> If I am using stdout redirection of a shell block to capture some text I am >> generating, errors need to go to stderr, but it would also be good if they >> went into the generated

bug#21919: tee enhancement

2015-11-16 Thread Paul Eggert
Tim Shaw wrote: echo big long complicated error message goes here | tee -2 How about "tee /dev/stderr" instead of a new option? "tee /dev/stderr" already works on many platforms now. We could easily arrange for it to work on the remaining platforms where it does not already work.

bug#21919: tee enhancement

2015-11-16 Thread isabella parakiss
On 11/14/15, Tim Shaw wrote: > If I am using stdout redirection of a shell block to capture some text I am > generating, errors need to go to stderr, but it would also be good if they > went into the generated output. For example > for i in files*; do > if

bug#21919: tee enhancement

2015-11-15 Thread Tim Shaw
If I am using stdout redirection of a shell block to capture some text I am generating, errors need to go to stderr, but it would also be good if they went into the generated output. For example for i in files*; do   if there_is_an_error; then     echo big long complicated error message goes