Skip to content

Latest commit

 

History

History
11 lines (9 loc) · 395 Bytes

process_substitution.md

File metadata and controls

11 lines (9 loc) · 395 Bytes

Process Substitution

What process substitution does is, it executes a command in subshell, and returns the stdout of that subshell as a file descriptor. We can make the file descriptor either readable or writable.

# read something from substituion
read < <(echo "HELLo")       # provides a readable fd
cat <(echo "hey" "whatsup")

# write something to it
cat file.txt > >(cat)