summaryrefslogtreecommitdiffstats
path: root/install/keymap
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2016-07-02 17:02:24 +0200
committerDave Reisner <dreisner@archlinux.org>2016-07-02 17:02:24 +0200
commit89bf8b56137196907b25e9d131e82dec90edaff0 (patch)
tree7636735fe72b77816abcf787ca5c2caeace1cc48 /install/keymap
parent08762d8401ff8e01a3c7a1558e69d5c30c983d20 (diff)
downloadmkinitcpio-89bf8b56137196907b25e9d131e82dec90edaff0.tar.gz
mkinitcpio-89bf8b56137196907b25e9d131e82dec90edaff0.tar.xz
keymap: fall back to us if KEYMAP is not defined
ref: https://bugs.archlinux.org/task/44805
Diffstat (limited to 'install/keymap')
-rw-r--r--install/keymap13
1 files changed, 4 insertions, 9 deletions
diff --git a/install/keymap b/install/keymap
index c1948b1..7de6acb 100644
--- a/install/keymap
+++ b/install/keymap
@@ -14,16 +14,11 @@ build() {
[[ $LANG ]] && LOCALE=$LANG
LANG=$l
- if [[ $KEYMAP ]]; then
- if [[ $LOCALE = *[Uu][Tt][Ff]?(-)8 ]]; then
- touch "$BUILDROOT/keymap.utf8"
- uc=-u
- fi
- loadkeys -q $uc $KEYMAP -b > "$BUILDROOT/keymap.bin"
- else
- warning "keymap: hook specified, but no KEYMAP found in configuration"
- return 1
+ if [[ $LOCALE = *[Uu][Tt][Ff]?(-)8 ]]; then
+ touch "$BUILDROOT/keymap.utf8"
+ uc=-u
fi
+ loadkeys -q $uc ${KEYMAP:-us} -b > "$BUILDROOT/keymap.bin"
) && add_runscript
}