Coreutils tee
From wikinotes
Tee reads from standard input,
and writes to a file(s)
in addition to the standard output.
Usage
# write input to multiple files echo foo | tee /out/file1 /out/file2 # pipe input to multiple commands echo foo | tee >(cat /dev/stdin) >(cat /dev/stdin)