I have a program that requires user input, which I save to a file by using tee:
tee program.in | program
I also have to capture stdout and stderr in another file. This does the trick
tee program.in | program > program.out 2>&1
The problem is that the user input is going to be based on what the program outputted before, so the user has to see the programs output in the terminal.
Any idea on how to accomplish this?
Another, more idiomatic
tee:-?, i.e.I hope this helps.
P.S. as you appear to be a new user, if you get an answer that helps you please remember to mark it as accepted, and/or give it a + (or -) as a useful answer.