[Novalug] Remap capslock to esc in Ubuntu

Garrett Nievin gnievin at comcast.net
Sat Feb 17 07:49:34 EST 2007


I'm still using the "AnyKey" keyboard which came with my Gateway 486 (the 
first box I installed Linux on - Yggdrasil in 1994).  Nifty keyboard in 
that you can remap keys, map simple "macros" onto a key, and change the 
repeat rate in the keyboard's firmware without the computer's knowledge 
or participation.  It's been in "Ctrl replaces CapsLock" mode for the 
past 13 years.

My laptop keyboard is not so clever, unfortunately.  For that, "dumpkeys" 
and "loadkeys" are my friends.

Cheers,
Garrett

On Wed, 14 Feb 2007, James Ewing Cottrell 3rd wrote:

> Yes, Mea Culpa, I didn't read the entire posting. In my rage I simply posted 
> a flame, answering the question I thought you asked. Which begs the question 
> of wny I was enraged in the first place.
>
> Like I said, "the key to the left of the A key should be a Control Key". This 
> is not Optional, this is Sacred.
>
> You see, unlike some of the Children here, I actually used dumb terminal for 
> 4/5 of my career. There are 24 years of history embedded in my fingers.
>
> In addition to the obvious Horrors that M$ has foisted upon us, one of the 
> most annoying insults is the physical one of remapping the keyboard. Yes, I 
> know that real typewriters have the Caps Lock key there, but really, who 
> actually NEEDS one of those???
>
> But, since my flame was based on a fallacy, it would seem like I owe you an 
> answer. Try doing a "man kbd" or "man keyboard" or ""man keymap" or similar. 
> Look in /etc/share/man/man4 for likely candidates.
>
> The actual keymaps are kept in a directory named something like 
> /usr/share/keymaps. Maybe there is a lib directory in there somewhere. Also 
> try "man -k key" and see what that gives you.
>
> You have to actually figure out which keyboard you are using, and I believe 
> that you have to chase down the chain of includes to find the correct entry.
>
> If you need an exact answer, I will track it down for you since I owe you, 
> and I need to actually doing it for myself, rather than putting up with it. I 
> mostly use X.
>
> JIM
>
> Luigi de Guzman wrote:
>
>> On Wed, 2007-02-14 at 19:03 -0500, James Ewing Cottrell 3rd wrote:
>> 
>>> If you want to do something like that....Figure It Out For Yourself!
>>> 
>>> I will give you a hint. Look at the man pages for xmodmap and xev. The 
>>> xmodmap man page give you an example about how to swap Caps Lock with Left 
>>> Control; you should be able to figire out the rest. Put it in a shell 
>>> script and run it from the program that starts up your X sessions or by 
>>> hand.
>>> 
>> 
>> 
>> This acknowledges my receipt of your wonderfully helpful RTFM for
>> Xmodmap, which I've already done.
>> 
>> The problem is that I'm not doing it for X;  I would like to do it in a
>> regular, non-X terminal in Ubuntu Dapper.
>> 
>> I have tried editing /etc/console-tools/remap  but have had no success
>> at remapping, even if I use the example line. . . 
>>
>> 
>>> Note that the key to the left of the A key should be a Control Key, not an 
>>> escape.
>>> 
>> 
>> . . . which is provided in the comments to /etc/console-tools/remap.
>> Not that you care, but I'd like to use vim rather than emacs, and the
>> esc key on my laptop keyboard is small and tough to reach.  I'm sure
>> I've violated some taboo, but you know what?  I'm not sure I really
>> care.
>> 
>> I would otherwise wish you a safe and warm evening, but I suspect the
>> burning fire of your Linux skills, so recently kindled by your skillful
>> use of an RTFM bomb on me, will keep you plenty warm.
>> 
>> -Luigi
>>
>> 
>>> JIM
>>> 
>>> luigi12081 at cox.net wrote:
>>>
>>> 
>>>> OK Novaluggers:
>>>> 
>>>> how does one change one's keymap so that "Capslock" becomes "escape" in 
>>>> the regular console? 
>>>> I know that keymaps are stored in /usr/share/keymaps/ as gzipped text 
>>>> files, but how are these read/loaded at startup?  What files would I have 
>>>> to edit and what script would I have to execute? 
>>>> I know that in X sessions, I'd have to use an xmodmap script, but I'm 
>>>> really looking to change the keymapping globally--both in and out of X.
>>>> 
>>>> Running Ubuntu Edgy (maybe feisty soon, when/if I sort out a wireless 
>>>> problem).
>>>> 
>>>> -Luigi
>>>> 
>>>> http://ouij.livejournal.com
>>>> _______________________________________________
>>>> Novalug mailing list
>>>> Novalug at calypso.tux.org
>>>> http://calypso.tux.org/cgi-bin/mailman/listinfo/novalug
>>>> 
>>>> 
>>>> 
>>>>
>>>> 
>> 
>> _______________________________________________
>> Novalug mailing list
>> Novalug at calypso.tux.org
>> http://calypso.tux.org/cgi-bin/mailman/listinfo/novalug
>> 
>>
>> 
>
> _______________________________________________
> Novalug mailing list
> Novalug at calypso.tux.org
> http://calypso.tux.org/cgi-bin/mailman/listinfo/novalug
>


More information about the Novalug mailing list