I want to pipe stdout to multiple files, but keep stdout itself quiet. tee
is close but it prints to both the files and stdout
$ echo 'hello world' | tee aa bb cc
hello world
This works but I would prefer something simpler if possible
$ echo 'hello world' | tee aa bb cc >/dev/null
tee aa bb cc
,tee
has to write 3 files, and you still havebash
redirecting standard output to a file. Intee aa bb > cc
, you have the bash redirect, buttee
only needs to write to 2 files. I'd say the 2nd is more efficient, but only in the strictest sense; you'll never notice the difference. – Libbie