coproc命令

http://wiki.bash-hackers.org/syntax/keywords/coproc


#let the output of the coprocess go to stdout
$ { coproc mycoproc { awk '{print "foo" $0;fflush()}'; } >&3; } 3>&1
[2] 23092
$ echo bar >&${mycoproc[1]}
$ foobar


你可能感兴趣的:(coproc命令)