grml-chroot: display usage info additionally to wrong number of arguments
authorTong Sun <suntong@cpan.org>
Sat, 29 Nov 2008 16:46:29 +0000 (17:46 +0100)
committerMichael Gebetsroither <gebi@grml.org>
Sat, 29 Nov 2008 16:49:17 +0000 (17:49 +0100)
usr_sbin/grml-chroot

index 4277c34..0985924 100755 (executable)
@@ -23,7 +23,7 @@ function printUsage
     cat <<EOT
 Usage: "$PROG_NAME_" NEWROOT [COMMAND....]
 
-$PROG_NAME__ is a chroot wrapper with proc/sys/pts/dev filesystem handling
+$PROG_NAME_ is a chroot wrapper with proc/sys/pts/dev filesystem handling
 
 EOT
 }
@@ -75,6 +75,7 @@ done
 shift $(($OPTIND - 1))
 
 if (( $# < 1 )); then
+    printUsage
     die "Wrong number of arguments."
 fi