chronic
Display stdout and stderr of a command if and only if it fails. tldr-pages
On several platforms
Several platforms
Display stdout and stderr of the specified command if and only if it produces a non-zero exit code or crashes
chronic command option1 option2 ...IdentifyDisplay stdout and stderr of the specified command if and only if it produces a non-empty stderr
chronic -e command option1 option2 ...IdentifyEnable verbose mode
chronic -v command option1 option2 ...Identify