I would like to have a script wherein all commands are tee
'd to a log file.
Right now I am running every command in the script thusly:
<command> | tee -a $LOGFILE
Is there a way to force every command in a shell script to pipe to tee
?
I cannot force users to add appropriate tee
ing when running the script, and want to ensure it logs properly even if the calling user doesn't add a logging call of their own.