4

So I have a ~/.config/autostart/keyboard.desktop file that tweaks my laptop keyboard layout on login. It does setxkbmap -option "ctrl:nocaps" amongst other things. This maps my caps lock key to ctrl. That part works fine. However, when I connect my bluetooth headset, somehow this setting is undone and my caps lock key goes back to being caps lock. I searched /etc/udev and there's only one script in there for a separate vendor that seems unrelated. How can I track down what's doing this, why, and how to avoid it?

1 Answers1

0

So it seems doing this via an autostart script that calls setxkbmap is not the right approach. I found this answer that explains how to set this in gnome via gsettings command line or dconf-editor or the main keyboard layout options GUI, and setting it that way seems to persist across USB/bluetooth disconnect/connects.