0

How can I split stdout to several parallel processes in one reading step? grep/sed is only an example

file AAA
AAA
BBB
CCC
DDD
EEE
FFF
cmd1 ($ cat AAA ) -----+---- cmd2 ( eg. grep "A" > fileA.txt ) ----->>
                       |
                       +---- cmd3 ( eg. sed -n -e '/^A/,/^D/p' > fileB.txt--->>
                       |
                       +---- cmd4 ( eg. grep "C" > fileC.txt ) ---->>
                       |
                       +---- cmd5 ( eg. grep "F" > fileF.txt ) ---->>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.