You're viewing a comment by Michael Hart and its responses.

Michael Hart Permalink
August 26, 2012, 10:08

I've always wanted to know how you can take a single process, pipe its stderr to one process and its stdout to another.

Any idea?

Comment Responses

August 26, 2012, 12:48

Easily! Use process substitution:

$ command > >(stdout_processor_command) 2> >(stderr_processor_command)

This sends stdout to stdout_processor_command and stderr to stderr_processor_command.

Reply To This Comment

(why do I need your e-mail?)

(Your twitter name, if you have one. (I'm @pkrumins, btw.))

Type the word "apple_329": (just to make sure you're a human)

Please preview the comment before submitting to make sure it's OK.