Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm using a German keyboard in Ubuntu. As we need the slash on the console quite often and it is somewhat awkward to type on a German keyboard, I'd like to assign the / key to the unused Caps Lock key.

Does anyone know how to do this?

share|improve this question

migrated from stackoverflow.com Aug 3 '11 at 13:04

This question came from our site for professional and enthusiast programmers.

2 Answers 2

You can always do it with 'xmodmap'.

Hope these links are useful,

http://askubuntu.com/questions/24916/how-do-i-remap-certain-keys

http://www.linuxscrew.com/2008/09/15/faq-how-to-disableremap-a-keyboard-key-in-linux/

FYI,

Caps Lock: keycode 66

Slash : keycode 61

share|improve this answer
    
Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. –  Tom Wijsman Jul 13 '12 at 15:09

Here are the exact commands:

cd ~
xmodmap -e "keycode 66 = slash"
`xmodmap -pke > .Xmodmap`
echo "xmodmap .Xmodmap" >> .xinitrc
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.