8

So I saw this question the other day. The user's K key was broken and they wanted to map it to Right-Shift. A good answer popped up and I thought I'd test it to see if it worked. I ran:

xmodmap -e "keycode 62 = k"

I did this under the understanding that I never use Right-Shift for anything. It turns out I was completely wrong. I use it all day long.

I've been filling up documents, corrupting commands, even almost deleting the wrong things (with Right-Shift+Delete). It's been a roller-coaster of emotions, but now I want it to go away. I'm sorry universe.

I know I could reboot or even just restart X but I have a load of things running and work to do. Can I just remove the mapping that xmodmap has created so that Right-Shift is just Right-Shift?

In this case it's just a single mapping (so Etcher Sketch approaches will work for me) but assume I have other mappings that I want to keep.

1

1 Answer 1

7

Try:

xmodmap -e "keycode 62 = Shift_R"

I used xmodmap -pke to see the list of current mappings, and look up Left-Shift. The right one follows from symmetry.

2
  • @Oli why/Have you not tried xmodmap command again (for selecting Right Shift) yourself?
    – Pandya
    Sep 11, 2014 at 11:21
  • @Pandya I wondered if it was a trick question, but then after a few tries I realised that the name for Right Shift might be the problem. Until I ran it with -pke I had guessed R_Shift, RShift, RightShift, etc.
    – muru
    Sep 11, 2014 at 11:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .