if [ $# -ne 3 ]; then
echo 1>&2 Usage: $0 19 Oct 91
exit 127
fi
What does "1>&2" ? Please let me know
if [ $# -ne 3 ]; then
echo 1>&2 Usage: $0 19 Oct 91
exit 127
fi
What does "1>&2" ? Please let me know
1 - stdout
2 - stderr
This means redirect echo's output to stderr, with a message on how to use the script,
there needs to be exactly three arguments.
All error conditions should go to stderr.