chronic
Display stdout and stderr of a command if and only if it fails.
More information: https://joeyh.name/code/moreutils/.
- Display
stdoutandstderrof the specified command if and only if it produces a non-zero exit code or crashes:
chronic command options …
- Display
stdoutandstderrof the specified command if and only if it produces a non-emptystderr:
chronic -e command options …
- Enable [v]erbose mode:
chronic -v command options …