Updating internal cmdline handling.
authorDaniel Baumann <daniel@debian.org>
Tue, 5 Jun 2012 16:23:15 +0000 (18:23 +0200)
committerDaniel Baumann <daniel@debian.org>
Tue, 5 Jun 2012 17:35:56 +0000 (19:35 +0200)
scripts/boot.sh
scripts/boot/cmdline.sh [moved from scripts/boot/arguments.sh with 97% similarity]

index d2a5c62..6304c97 100755 (executable)
@@ -444,7 +444,14 @@ mountroot ()
 
        . /live.vars
 
-       Arguments
+       _CMDLINE="$(cat /proc/cmdline)"
+       Cmdline
+
+       case "${LIVE_DEBUG}" in
+               true)
+                       set -x
+                       ;;
+       esac
 
        case "${LIVE_READ_ONLY}" in
                true)
similarity index 97%
rename from scripts/boot/arguments.sh
rename to scripts/boot/cmdline.sh
index 5f34512..18a9a2c 100755 (executable)
@@ -2,11 +2,11 @@
 
 #set -e
 
-Arguments ()
+Cmdline ()
 {
-       for ARGUMENT in $(cat /proc/cmdline)
+       for _PARAMETER in ${_CMDLINE}
        do
-               case "${ARGUMENT}" in
+               case "${_PARAMETER}" in
                        live-boot.read-only|read-only)
                                LIVE_READ_ONLY="true"
                                export LIVE_READ_ONLY
@@ -17,7 +17,13 @@ Arguments ()
                                export LIVE_VERIFY_CHECKSUMS
                                ;;
 
-                       # parameters below need review
+                       # Special options
+                       live-boot.debug|debug)
+                               LIVE_DEBUG="true"
+                               ;;
+
+
+                       # parameters below need review (FIXME)
                        skipconfig)
                                NOFASTBOOT="true"
                                NOFSTAB="true"
@@ -30,13 +36,6 @@ Arguments ()
                                BOOTIF="${x#BOOTIF=}"
                                ;;
 
-                       debug)
-                               DEBUG="true"
-                               export DEBUG
-
-                               set -x
-                               ;;
-
                        dhcp)
                                # Force dhcp even while netbooting
                                # Use for debugging in case somebody works on fixing dhclient