Adding casper 1.81+debian-1.
[live-boot-grml.git] / scripts / casper-bottom / 19keyboard
index 81cce72..40834d8 100755 (executable)
@@ -1,7 +1,7 @@
 #!/bin/sh
 
 PREREQ=""
-DESCRIPTION="Setting up keyboard..."
+DESCRIPTION="Setting up console keyboard..."
 
 . /scripts/casper-functions
 
@@ -20,7 +20,7 @@ esac
 
 log_begin_msg "$DESCRIPTION"
 
-kbd=us
+kbd=
 cslayout=
 csvariant=
 csmodel=
@@ -28,15 +28,20 @@ csmodel=
 # commandline
 if [ -n "${KBD}" ]; then
     kbd="${KBD}"
+else
+    kbd=us
 fi
-if [ -n "${CSLAYOUT}" ]; then
-    cslayout="${CSLAYOUT}"
+
+really_export kbd
+
+if [ -n "${KLAYOUT}" ]; then
+    cslayout="${KLAYOUT}"
 fi
-if [ -n "${CSVARIANT}" ]; then
-    csvariant="${CSVARIANT}"
+if [ -n "${KVARIANT}" ]; then
+    csvariant="${KVARIANT}"
 fi
-if [ -n "${CSMODEL}" ]; then
-    csmodel="${CSMODEL}"
+if [ -n "${KMODEL}" ]; then
+    csmodel="${KMODEL}"
 fi
 
 if [ -x /root/bin/setupcon ] && [ -f /root/etc/default/console-setup ]; then
@@ -63,5 +68,6 @@ if [ -x /root/bin/setupcon ] && [ -f /root/etc/default/console-setup ]; then
 else
         chroot /root /usr/sbin/install-keymap $kbd
         casper-preseed /root debian-installer/keymap "$kbd"
+        casper-preseed /root kbd-chooser/method "$kbd"
 fi
 log_end_msg