summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpico.dev <pico.dev@gmail.com>2020-07-18 10:09:54 +0200
committerpico.dev <pico.dev@gmail.com>2020-07-18 10:09:54 +0200
commita22b6e427922cf03468fa5750c8e332a6466cc39 (patch)
treedc1a264a9dfcbe0e6b95b48d1f693a920bf959c3
parentcb464157fcccb8374e73710e6b6f57ebdd0d5a74 (diff)
Add a model, variant and options in 00-keyboard.conf
Fixes #94
-rw-r--r--alis.conf3
-rw-r--r--alis.sh16
2 files changed, 18 insertions, 1 deletions
diff --git a/alis.conf b/alis.conf
index 256127e..8350c18 100644
--- a/alis.conf
+++ b/alis.conf
@@ -45,6 +45,9 @@ LOCALES=("es_ES.UTF-8 UTF-8" "en_GB.UTF-8 UTF-8")
LOCALE_CONF=("LANG=es_ES.UTF-8" "LANGUAGE=es_ES:es:en_GB:en")
KEYMAP="KEYMAP=es"
KEYLAYOUT="es"
+KEYMODEL=""
+KEYVARIANT=""
+KEYOPTIONS=""
FONT=""
FONT_MAP=""
HOSTNAME="archlinux"
diff --git a/alis.sh b/alis.sh
index 5952c40..a0e7bbf 100644
--- a/alis.sh
+++ b/alis.sh
@@ -600,6 +600,20 @@ function configuration() {
echo -e "$KEYMAP\n$FONT\n$FONT_MAP" > /mnt/etc/vconsole.conf
echo $HOSTNAME > /mnt/etc/hostname
+ OPTIONS=""
+ if [ -n "$KEYLAYOUT" ]; then
+ OPTIONS="$OPTIONS"$'\n'" Option \"XkbLayout\" \"$KEYLAYOUT\""
+ fi
+ if [ -n "$KEYMODEL" ]; then
+ OPTIONS="$OPTIONS"$'\n'" Option \"XkbModel\" \"$KEYMODEL\""
+ fi
+ if [ -n "$KEYVARIANT" ]; then
+ OPTIONS="$OPTIONS"$'\n'" Option \"XkbVariant\" \"$KEYVARIANT\""
+ fi
+ if [ -n "$KEYOPTIONS" ]; then
+ OPTIONS="$OPTIONS"$'\n'" Option \"XkbOptions\" \"$KEYOPTIONS\""
+ fi
+
arch-chroot /mnt mkdir -p "/etc/X11/xorg.conf.d/"
cat <<EOT > /mnt/etc/X11/xorg.conf.d/00-keyboard.conf
# Written by systemd-localed(8), read by systemd-localed and Xorg. It's
@@ -608,7 +622,7 @@ function configuration() {
Section "InputClass"
Identifier "system-keyboard"
MatchIsKeyboard "on"
- Option "XkbLayout" "$KEYLAYOUT"
+ $OPTIONS
EndSection
EOT