Last active
March 24, 2019 06:16
-
-
Save miguelmota/b4731416a1b38853759be197a734d221 to your computer and use it in GitHub Desktop.
Bash pipe to file descriptor 3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# not supported by all platforms | |
command | tee /dev/fd/3 | |
# cross-platform compatible using process substitution (recommended) | |
command > >(tee >(cat >&3)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment