LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Blogs > smilingfrog
User Name
Password

Notices


Rate this Entry

Swapping the Escape and Caps Lock in console

Posted 02-27-2017 at 01:55 PM by smilingfrog
Updated 02-27-2017 at 04:22 PM by smilingfrog

http://superuser.com/questions/29011...eymap-in-linux
http://askubuntu.com/questions/15738...nd-line-system

I swap Caps_Lock and Escape for editing with vim, and although easy to do in X, I never figured out how to swap the keys in console terminals.
The above links to a nice method to reassign keymaps so that the caps and esc keys are swapped.

Code:
keycode 58 = Escape Escape Escape
keycode  1 = Caps_Lock Caps_Lock Caps_Lock
This file can be saved in /usr/share/keymaps in the appropriate keymap folder; I called it swapCapsEsc.map
In LFS, this can be mapped directly in the /etc/sysconfig/console as a KEYMAP_CORRECTIONS variable
Code:
KEYMAP="us"
KEYMAP_CORRECTIONS="swapCapsEsc"
No need to load it in the runtime commands.
Posted in Uncategorized
Views 980 Comments 0
« Prev     Main     Next »
Total Comments 0

Comments

 

  



All times are GMT -5. The time now is 05:46 AM.

Main Menu
Advertisement
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration