[Fai-commit] r5667 - in trunk: debian lib

Thomas Lange lange at alioth.debian.org
Tue Nov 17 10:11:01 UTC 2009


Author: lange
Date: 2009-11-17 10:11:01 +0000 (Tue, 17 Nov 2009)
New Revision: 5667

Modified:
   trunk/debian/changelog
   trunk/lib/load_keymap_consolechars
Log:
load_keymap_consolechars: add code for usage of setupcon (thanks to
Waldemar)

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog	2009-11-16 17:22:12 UTC (rev 5666)
+++ trunk/debian/changelog	2009-11-17 10:11:01 UTC (rev 5667)
@@ -4,9 +4,11 @@
   * make-fai-nfsroot: do not remove fai.conf from upstart directory
     (Thanks to Waldemar Brodkorb for the patch)
   * fai-guide.txt: minor fixes (Thanks to Waldemar for the patch)
+  * load_keymap_consolechars: add code for usage of setupcon (thanks to
+    Waldemar)
   * THANKS: add Waldemar
 
- -- Thomas Lange <lange at debian.org>  Mon, 16 Nov 2009 18:20:49 +0100
+ -- Thomas Lange <lange at debian.org>  Tue, 17 Nov 2009 11:03:32 +0100
 
 fai (3.3.1) unstable; urgency=low
 

Modified: trunk/lib/load_keymap_consolechars
===================================================================
--- trunk/lib/load_keymap_consolechars	2009-11-16 17:22:12 UTC (rev 5666)
+++ trunk/lib/load_keymap_consolechars	2009-11-17 10:11:01 UTC (rev 5667)
@@ -9,4 +9,16 @@
 [ "$KEYMAP" ] || exit
 
 echo -n "Loading keymap(s) $KEYMAP ..."
-loadkeys -q $KEYMAP && echo "done."
+if [ -x /bin/setupcon ]; then
+
+    layout=$(echo $KEYMAP|cut -d - -f 1)
+    variant=$(echo $KEYMAP|cut -d - -f 3)
+    sed -e "s#^XKBLAYOUT=.*#XKBLAYOUT=\"$layout\"#" \
+        -e "s#^XKBVARIANT=.*#XKBVARIANT=\"$variant\"#" \
+	/etc/default/console-setup > /.console-setup
+    setupcon -k --force
+    echo "done."
+else
+    loadkeys -q $KEYMAP && echo "done."
+fi
+




More information about the Fai-commit mailing list