I have bunch of commands in a shell script e.g
ls -ltr /export/home/user/clients/
$clientDir
> $HOME/user.out
which I am outputting to a file. But when the command fails even that I want to output to the same file. But now when the command fails it outputs the error to the file it just prints to the console. Please advise.
Start Free Trial