Artificial intelligent assistant

evaluate multiple patterns from program output and write into pattern specific files I have a script outputting some value/numbers and I want to split those into two files. I am looking at something like: ./runme.sh | grep 'ook' >> ook.out | grep 'eek' >> eek.out Where the second pipe should not, as is the case, take the output of the first grep but that of runme.sh. Is that possible?

That's perfect use case for the utility `pee`.

`./runme.sh | pee "grep ook >> ook.out" "grep eek >> eek.out"`

In Debian & derivatives, `pee` is found in `moreutils` package.

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy f7c6f8b29d286020c23d82aa746a8349