|
From: | Jirka Hladky |
Subject: | Re: Enhancement request for tee - please add the option to not quit on SIGPIPE when someother files are still opened |
Date: | Sat, 21 Nov 2015 00:58:18 +0100 |
Bernhard Voelker wrote:
> I'm not convinced that a new --no-stdout option is warranted:
> why not simply redirect stdout to the last fifo?
>
> cat /dev/zero | head -c500M \
> | (/dev/shm/AAA/coreutils-8.24/src/tee -p \
> $d/fifo1 $d/fifo2 $d/fifo3 > $d/fifo4 ) 2>&1 \
> | > tee $d/run.log &
Of course! It was so obvious that we missed seeing it! Simply do a
normal redirect of stdout to the process. Thanks Bernhard for
pointing this out.
This is also true of the >(process substitutions) too.
echo foo | tee >(sleep 2 && cat) > >(sleep 5 && cat)
This really argues against any need for --no-stdout. Because if one
wants --no-stdout it means one has forgotten about a normal
redirection.
Bob
[Prev in Thread] | Current Thread | [Next in Thread] |