FIX: Use standard error for die() and dieWithHelp()

By convention, error output should be printed to standard error, not standard out. Same for the usage help that may accompany the error message.
This commit is contained in:
Ingo Karkat
2023-01-21 18:59:32 +01:00
parent ea32af34e6
commit 803881998f

View File

@@ -349,14 +349,14 @@ dieWithHelp()
case "$1" in
help) help;;
shorthelp) shorthelp;;
esac
esac >&2
shift
die "$@"
}
die()
{
echo "$*"
echo >&2 "$*"
exit 1
}