]> git.proxmox.com Git - grub2.git/commitdiff
fix remaining scripts
authorBVK Chaitanya <bvk.groups@gmail.com>
Sun, 7 Feb 2010 05:01:04 +0000 (10:31 +0530)
committerBVK Chaitanya <bvk.groups@gmail.com>
Sun, 7 Feb 2010 05:01:04 +0000 (10:31 +0530)
util/grub-reboot.in
util/grub-set-default.in
util/i386/efi/grub-install.in
util/ieee1275/grub-install.in
util/powerpc/ieee1275/grub-mkrescue.in

index 20f2b10bcef721a36367d95763c09bcbb965860d..eb7073e02b239c4ed81f9ac6a7b9a0eff44d6bc8 100644 (file)
@@ -45,7 +45,11 @@ EOF
 }
 
 # Check the arguments.
-for option in "$@"; do
+while test $# -gt 0
+do
+    option=$1
+    shift
+
     case "$option" in
     -h | --help)
        usage
@@ -53,8 +57,12 @@ for option in "$@"; do
     -v | --version)
        echo "grub-reboot (GNU GRUB ${PACKAGE_VERSION})"
        exit 0 ;;
+
+    --root-directory)
+       rootdir=$1; shift ;;
     --root-directory=*)
        rootdir=`echo "$option" | sed 's/--root-directory=//'` ;;
+
     -*)
        echo "Unrecognized option \`$option'" 1>&2
        usage
index 4d7c10e8efc702c089e362edfb29bf639a62c4f4..2636543c3843b70622d07629ef0d31e1bc380a40 100644 (file)
@@ -45,7 +45,11 @@ EOF
 }
 
 # Check the arguments.
-for option in "$@"; do
+while test $# -gt 0
+do
+    option=$1
+    shift
+
     case "$option" in
     -h | --help)
        usage
@@ -53,8 +57,12 @@ for option in "$@"; do
     -v | --version)
        echo "grub-set-default (GNU GRUB ${PACKAGE_VERSION})"
        exit 0 ;;
+
+    --root-directory)
+       rootdir=$1; shift ;;
     --root-directory=*)
        rootdir=`echo "$option" | sed 's/--root-directory=//'` ;;
+
     -*)
        echo "Unrecognized option \`$option'" 1>&2
        usage
index caa7be7e4fd4ca241557a1faca36ce54df78783c..b93525e3e12219296ee4e99c4014b0ea0a466543 100644 (file)
@@ -71,7 +71,11 @@ EOF
 }
 
 # Check the arguments.
-for option in "$@"; do
+while test $# -gt 0
+do
+    option=$1
+    shift
+
     case "$option" in
     -h | --help)
        usage
@@ -79,16 +83,32 @@ for option in "$@"; do
     -v | --version)
        echo "grub-install (GNU GRUB ${PACKAGE_VERSION})"
        exit 0 ;;
+
+    --modules)
+        modules=$1; shift ;;
     --modules=*)
        modules=`echo "$option" | sed 's/--modules=//'` ;;
+
+    --root-directory)
+       rootdir=$1; shift ;;
     --root-directory=*)
        rootdir=`echo "$option" | sed 's/--root-directory=//'` ;;
+
+    --grub-mkimage)
+       grub_mkimage=$1; shift ;;
     --grub-mkimage=*)
        grub_mkimage=`echo "$option" | sed 's/--grub-mkimage=//'` ;;
+
+    --grub-mkdevicemap)
+       grub_mkdevicemap=$1; shift ;;
     --grub-mkdevicemap=*)
        grub_mkdevicemap=`echo "$option" | sed 's/--grub-mkdevicemap=//'` ;;
+
+    --grub-probe)
+       grub_probe=$1; shift ;;
     --grub-probe=*)
        grub_probe=`echo "$option" | sed 's/--grub-probe=//'` ;;
+
     --no-floppy)
        no_floppy="--no-floppy" ;;
     --recheck)
index 97c485d5587d8edae5a40417c91dfa9a76766fdb..63dde62b35482295e180bd1b6aa0fe180c1a9445 100644 (file)
@@ -75,7 +75,11 @@ EOF
 }
 
 # Check the arguments.
-for option in "$@"; do
+while test $# -gt 0
+do
+    option=$1
+    shift
+
     case "$option" in
     -h | --help)
        usage
@@ -83,16 +87,32 @@ for option in "$@"; do
     -v | --version)
        echo "grub-install (GNU GRUB ${PACKAGE_VERSION})"
        exit 0 ;;
+
+    --modules)
+       modules=$1; shift ;;
     --modules=*)
        modules=`echo "$option" | sed 's/--modules=//'` ;;
+
+    --root-directory)
+       rootdir=$1; shift ;;
     --root-directory=*)
        rootdir=`echo "$option" | sed 's/--root-directory=//'` ;;
+
+    --grub-mkdevicemap)
+       grub_mkdevicemap=$1; shift ;;
     --grub-mkdevicemap=*)
        grub_mkdevicemap=`echo "$option" | sed 's/--grub-mkdevicemap=//'` ;;
+
+    --grub-mkimage)
+       grub_mkimage=$1; shift ;;
     --grub-mkimage=*)
        grub_mkimage=`echo "$option" | sed 's/--grub-mkimage=//'` ;;
+
+    --grub-probe)
+       grub_probe=$1; shift ;;
     --grub-probe=*)
        grub_probe=`echo "$option" | sed 's/--grub-probe=//'` ;;
+
     --no-nvram)
        update_nvram=no ;;
     # This is an undocumented feature...
index 0110e799cd5581d310fdeb2c97ab960d13e2a489..375adb0cb2098d70fba69ea423ffd30c3cad2d94 100644 (file)
@@ -55,7 +55,11 @@ EOF
 input_dir=${pkglibdir}
 
 # Check the arguments.
-for option in "$@"; do
+while test $# -gt 0
+do
+    option=$1
+    shift
+
     case "$option" in
     -h | --help)
        usage
@@ -63,12 +67,22 @@ for option in "$@"; do
     -v | --version)
        echo "grub-mkrescue (GNU GRUB ${PACKAGE_VERSION})"
        exit 0 ;;
+
+    --modules)
+       modules=$1; shift ;;
     --modules=*)
        modules=`echo "$option" | sed 's/--modules=//'` ;;
+
+    --pkglibdir)
+       input_dir=$1; shift ;;
     --pkglibdir=*)
        input_dir=`echo "$option" | sed 's/--pkglibdir=//'` ;;
+
+    --grub-mkimage)
+       grub_mkimage=$1; shift ;;
     --grub-mkimage=*)
        grub_mkimage=`echo "$option" | sed 's/--grub-mkimage=//'` ;;
+
     -*)
        echo "Unrecognized option \`$option'" 1>&2
        usage