urxvt lesskey fix for HOME and END in Fluxbox 13.37

If you have any suggestions or ideas about improving Salix, here's the place to post them.
Post Reply
User avatar
jayseye
Posts: 233
Joined: 24. Jul 2011, 17:22
Location: Brownsmead, Oregon (Center of the Universe)

urxvt lesskey fix for HOME and END in Fluxbox 13.37

Post by jayseye »

Hi -

Thanks to Salix, an update from Slackware 12.2 went smoothly. One tweak solved a minor annoyance: in the urxvt terminal, the HOME and END keys behaved differently in the 'less' pager.

To restore the traditional key functions, these lines can be saved as a file named $HOME/.lesskey (for use with the 'lesskey' command):

Code: Select all

#command 
\e[1~ goto-line 
\e[4~ goto-end 

To apply those changes, the full 'lesskey' syntax for a single user is:

Code: Select all

lesskey -o  $HOME/.less $HOME/.lesskey 

To apply system-wide the syntax is:

Code: Select all

lesskey -o /etc/sysless $HOME/.lesskey 

That system-wide command may require 'sudo' or 'su' depending on your user permissions.

One note of caution: the 'lesskey' command will overwrite any existing lesskey definitions.

An earlier posting mentioned a similar tweak:

> viewtopic.php?f=17&t=2009&p=12901&hilit=less+home+end#p12901

However, in Fluxbox 13.37 the HOME and END keys work fine everywhere except in the 'less' pager, so the 'lesskey' approach detailed above seems to be a more targeted solution.

Hope this info may be helpful to others.

Regards,
jayseye
Post Reply