My Macbook Pro's keyboard is malfunctioning and both its shift keys are pressing erratically. Other than that, it is fine.
In Macos 10.11, I solved that problem by using karabiner.
In Linux, Xmodmap didn't worK. Is there some command on setxkbmap that would work?
/etc/default/keyboard
adding the lineXKBOPTIONS="caps:swapescape"
to swap my caps lock and my escape key for using Vim. I think you can disable keys as well by using this file. These changes are system wide for all users. I'd add an answer if I had time to look into it fully for you. Also, I'm on Debian. askubuntu.com/questions/342066/… I also needed to installconsole-common
andconsole-data
for it to work (in Debian)./etc/default/keyboard
by rebooting without having to runsudo dpkg-reconfigure keyboard-configuration
.