I'm running a memory check tool (prog1) on a C++ code (prog2), both of which give me a huge and detailed output. In order to chase down some bugs I need to save this output to a file.
I tried redirecting the stdout to a file:
prog1 prog2 > outfile.txt
But that gives me a file containing the output of prog2, while the output of prog1 is still going to the terminal.
Anyone know a way to specify that I want BOTH outputs to go to a file? Like
(prog1 prog2) > outfile.txt?