I have bought an US laptop with US keyboard but didn't come with a key next to Z that type the braces < >.

I don't have experience with keyboard mapping, i would like help to be able to map the Right Ctrl key, to be the braceleft < and the Shift+Right Ctrl to be the braceright >.

1 Answer 1


You can use xmodmap.

Create a file named .Xmodmap in your home directory, and add the following code:

keycode 105 = less greater

Save the file, logout and log back in. If the bindings do not take, run xmodmap .Xmodmap from the terminal and add the command to your .bashrc file.

More details: You can see individual keycodes by running xev in the terminal and pressing any key. xmodmap -pk will print all the current keybindings and names of keys.

  • Doesn't your keyboard have < and > above the comma (,) and period (.) as all US keyboards? Still useful to know how to remap keys. I use code similar to the above to map right control to Menu on my older keyboard that lacks this key. Jun 9, 2016 at 21:06
  • Yes it has those keys, but i use Portuguese layout with it, so they type differently. Jun 9, 2016 at 21:48
  • Of course. That makes perfect sense. I'm glad it is working. Jun 10, 2016 at 22:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.