From 513ad2e7514c68436e3814bea8eec8d301efcf53 Mon Sep 17 00:00:00 2001 From: Kousuke Saruta Date: Sun, 10 Aug 2014 01:06:15 +0900 Subject: [PATCH] Modified util.sh to enable to use option including white spaces --- bin/utils.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/bin/utils.sh b/bin/utils.sh index 9c5fef1a42667..7aaaf2b941f46 100644 --- a/bin/utils.sh +++ b/bin/utils.sh @@ -30,7 +30,7 @@ function gatherSparkSubmitOpts() { SUBMISSION_OPTS=() APPLICATION_OPTS=() while (($#)); do - case $1 in + case "$1" in --master | --deploy-mode | --class | --name | --jars | --py-files | --files | \ --conf | --properties-file | --driver-memory | --driver-java-options | \ --driver-library-path | --driver-class-path | --executor-memory | --driver-cores | \ @@ -39,16 +39,16 @@ function gatherSparkSubmitOpts() { "$SUBMIT_USAGE_FUNCTION" exit 1; fi - SUBMISSION_OPTS+=($1); shift - SUBMISSION_OPTS+=($1); shift + SUBMISSION_OPTS+=("$1"); shift + SUBMISSION_OPTS+=("$1"); shift ;; --verbose | -v | --supervise) - SUBMISSION_OPTS+=($1); shift + SUBMISSION_OPTS+=("$1"); shift ;; *) - APPLICATION_OPTS+=($1); shift + APPLICATION_OPTS+=("$1"); shift ;; esac done