5
2
When I use the unix command 'less' I am constantly frustrated that using the Enter key on the numeric keypad doesn't work but instead types 'ESCOM'.
Is there a way to fix that?
5
2
When I use the unix command 'less' I am constantly frustrated that using the Enter key on the numeric keypad doesn't work but instead types 'ESCOM'.
Is there a way to fix that?
6
This is because the number pad's Enter key sends a different command then the keyboard Enter key. You could globally re-map the key to send the normal Return/Enter command, but understand that it will effect how the key works in all the other programs too.
Here are some tips on how to remap the key in X-Windows using xmodmap, or in the console/terminal using loadkeys. You probably want to map keycode 104 ("KP_Enter") to the "Return" command.
1
Use lesskey
.
~ $ vi .lesskey
#command
\OM forw-line
~ $ lesskey
If this character doesn't match the one in your keyboard try using the escaped octal value.
You can also use another action like invalid
(beeps) or noaction
.
I am still lost. How do I find out the octal value? How can I make this change permanent? What does \OM
mean? What does forw-line
mean? Why the comment at the top, has it any relevance? – donquixote – 2016-08-09T20:03:21.733
The commands above should be enough, provided you know lesskey
or read the linked man
page. – 1.61803 – 2016-08-10T20:52:54.507
1The articles contain too much unrelated information. A simple excerpt would be great! – donquixote – 2016-08-09T19:57:07.973