Ubuntu – Deactivate Caps Lock in 14.04

14.04capslockkeyboardkeyboard-layout

I really don't need caps lock (who does?) and would rather have it as a shift key as I sometimes hit it by mistake especially on the small netbook keyboard. Since I don't read while I type this might mean I have to retype half a page. I only find solutions for Ubuntu 12 but they don't work for 14 (Somehow the "typing" dialog looks totally different, not as user friendly). I've tried anyway and clicked on + to make a custom shortcut. It asked me for a name (I put Name: Caps clock) and for a command (command: disable, and I also tried command: shift), but that did nothing. It shows on right side under custom shortcut, but I still have caps lock. I am new at linux so please, if you have an answer don't just say: Use mxpt.de or so, but please tell me how to get to the dialog box or to a command prompt and what I need to do. (Somebody had a solution with Gnome Tweak or so, but I cannot find that program in Ubuntu 14). Thanks

Best Answer

Opening a terminal and typing in:

xmodmap -e "keycode 66 = Shift_L NoSymbol Shift_L" 

followed by enter/return should remap the Caps Lock button the Left Shift.

However, this will need to be executed on each boot. You can do the following to automatically run this every time the system boots.

  1. Search "Startup Applications" in the dash and open it.

  2. Click add. For the name put "Caps Lock to Shift" and under "command" put xmodmap -e "keycode 66 = Shift_L NoSymbol Shift_L".

  3. Press save and restart. Enjoy!


If you would rather disable Caps Lock, you can execute the following (in terminal):

setxkbmap -option caps:none

Once again, this will reset once you restart, so add a startup entry (like above) to execute this on boot.

Related Question