mirror of
https://github.com/fish-shell/fish-shell
synced 2024-11-14 08:58:01 +00:00
885d16fcd6
darcs-hash:20061031152316-ac50b-e68db9853d6e9461a0c054f1ea290704ccfc0a31.gz
20 lines
848 B
Text
20 lines
848 B
Text
\section psub psub - perform process substitution
|
|
|
|
\subsection psub-synopsis Synopsis
|
|
<tt>COMMAND1 (COMMAND2|psub) </tt>
|
|
|
|
\subsection psub-description Description
|
|
|
|
Posix shells feature a syntax that is a mix between command
|
|
substitution and piping, called process substitution. It is used to
|
|
send the output of a command into the calling command, much like
|
|
command substitution, but with the difference that the output is not
|
|
sent through commandline arguments but through a named pipe, with the
|
|
filename of the named pipe sent as an argument to the calling
|
|
program. The psub shellscript function, which when combined with a
|
|
regular command substitution provides the same functionality.
|
|
|
|
\subsection psub-example Example
|
|
|
|
<tt>diff (sort a.txt|psub) (sort b.txt|psub)</tt> shows the difference
|
|
between the sorted versions of files a.txt and b.txt.
|