From 1584694068d5f4a9ae8aa842721e4ad322135183 Mon Sep 17 00:00:00 2001 From: Michael Prokop Date: Fri, 27 Jul 2012 14:43:07 +0200 Subject: [PATCH] Display usage information if any unknown cmdline option is used This is more user friendly than just displaying an error message --- grml-live | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/grml-live b/grml-live index 45b93e6..3964cbd 100755 --- a/grml-live +++ b/grml-live @@ -333,7 +333,7 @@ while getopts "a:C:c:d:D:e:g:i:I:o:r:s:t:U:v:AbBFhnNqQuVz" opt; do U) CHOWN_USER="$OPTARG" ;; V) VERBOSE="-v" ;; z) SQUASHFS_ZLIB=1 ;; - ?) echo "invalid option -$OPTARG" >&2; bailout 1 ;; + ?) echo "invalid option -$OPTARG" >&2; usage; bailout 1 ;; esac done shift $(($OPTIND - 1)) # set ARGV to the first not parsed commandline parameter -- 2.1.4