MAPREDUCE-5033. mapred shell script should respect usage flags (--help -help -h). Contributed by Andrew Wang.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1450584 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Aaron Myers 2013-02-27 02:42:38 +00:00
parent 12985ea6f9
commit 42e987f11e
2 changed files with 11 additions and 0 deletions

View File

@ -163,6 +163,9 @@ Release 2.0.4-beta - UNRELEASED
IMPROVEMENTS
MAPREDUCE-5033. mapred shell script should respect usage flags
(--help -help -h). (Andrew Wang via atm)
OPTIMIZATIONS
BUG FIXES

View File

@ -50,6 +50,14 @@ fi
COMMAND=$1
shift
case $COMMAND in
# usage flags
--help|-help|-h)
print_usage
exit
;;
esac
if [ "$COMMAND" = "job" ] ; then
CLASS=org.apache.hadoop.mapred.JobClient
elif [ "$COMMAND" = "queue" ] ; then