Answers for "process substitution vs command substitution"

1

process substitution vs command substitution

A command substitution ( $(...) ) will be replaced by the output of the command,
while a process substitution ( <(...) ) will be replaced by a filename from 
which the output of the command may be read.

$ unset t
$ echo "$( t=1234; echo "$t" )"
1234
$ echo "$t"
(empty line output)

$ unset t
$ cat <( t=4321; echo "$t" )
4321
$ echo "$t"
(empty line output)
Posted by: Guest on October-03-2021

Code answers related to "process substitution vs command substitution"

Browse Popular Code Answers by Language