summaryrefslogtreecommitdiff
path: root/guides/sysadmin/console.org
diff options
context:
space:
mode:
authorKévin Le Gouguec <kevin.legouguec@gmail.com>2025-01-18 19:00:03 +0100
committerKévin Le Gouguec <kevin.legouguec@gmail.com>2025-01-18 19:00:03 +0100
commit3eb4d872f7157b67691fb5a98e2cf53f716c5457 (patch)
treef8a994a39e359e2620ff01baa2e1096f7e0da633 /guides/sysadmin/console.org
parent9398b60e08f07022cf02bb290f36718b1c744eae (diff)
downloadmemory-leaks-3eb4d872f7157b67691fb5a98e2cf53f716c5457.tar.xz
Resume gratuitous shuffling
Diffstat (limited to 'guides/sysadmin/console.org')
-rw-r--r--guides/sysadmin/console.org19
1 files changed, 19 insertions, 0 deletions
diff --git a/guides/sysadmin/console.org b/guides/sysadmin/console.org
new file mode 100644
index 0000000..a6839c1
--- /dev/null
+++ b/guides/sysadmin/console.org
@@ -0,0 +1,19 @@
+* Keyboard settings
+Debian's =console-setup= package provides =setupcon=, a neat utility
+that reads XKB settings from =/etc/default/keyboard= and translates
+them to whatever format the Linux console understands.
+
+To get something similar to =ctrl:nocaps= on distros that do not
+feature this utility:
+#+begin_src sh
+$ localectl | grep "VC Keymap" # To spot the current KEYMAP.
+$ sudo mkdir -p /usr/local/share/kbd/keymaps
+# KEYMAPS_DIR: depending on the distro:
+# - /usr/share/kbd/keymaps/xkb
+# - /lib/kbd/keymaps/xkb
+$ gunzip --stdout ${KEYMAPS_DIR}/${KEYMAP}.map.gz |
+ sed 's/^keycode 58 = .*$/keycode 58 = Control/' |
+ sudo tee /usr/local/share/kbd/keymaps/${KEYMAP}-nocaps.map
+# In /etc/vconsole.conf, change KEYMAP to ^this^ absolute filename.
+# Reboot.
+#+end_src