2

I have a binary that outputs to a terminal window when running. I wish to start this binary from a shell script, because I need to set a environment variable first.

But, when it's executed from:

#!/bin/bash
export THIS=set
./binary

I can no longer see the binary's output to terminal... How can I get the output while executing with a script?

2

Solved by

./binary | tee /dev/tty

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.