From eefda84832ad395c843ccc55591e23a6c316c844 Mon Sep 17 00:00:00 2001 From: George Danchev Date: Fri, 15 Jul 2011 17:57:05 +0000 Subject: [PATCH] rework to match latest option handling --- releng/run_all_releng | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/releng/run_all_releng b/releng/run_all_releng index aec83ab6..2f31f6b1 100755 --- a/releng/run_all_releng +++ b/releng/run_all_releng @@ -25,19 +25,25 @@ RELENG_XORRISO= CLEANUP_LOG=0 ############################################# -while getopts "x:k:c:f:h" OPT +next_is= +for i in "$@" do - case $OPT in - x) - RELENG_XORRISO=$OPTARG - ;; - c) - CLEANUP_LOG=1 - ;; - *) - ;; - esac + if test "$next_is" = "ignore" + then + dummy=dummy + elif test "$next_is" = "x" + then + RELENG_XORRISO="$i" + next_is= + elif test x"$i" = x"-x" + then + next_is="x" + elif test x"$i" = x"-c" + then + CLEANUP_LOG=1 + fi done +############################################# if [ ! "${1}" ]; then cat << HLP @@ -52,10 +58,10 @@ required space for these data is about 300 megabytes. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ examples: # run xorriso and keep the self generated data - $ ./${SELF} -x path/to/xorriso [-k1] + $ ./${SELF} -x path/to/xorriso [-k] # clean up self generated data from previous run - $ ./${SELF} -c1 + $ ./${SELF} -c ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ HLP exit 31