less
already uses j/k for vertical scrolling, but not h/l for horizontal scrolling (in --ch
mode). The l key isn't bound to anything anyway, and h is just a synonym for H, so I wouldn't overwrite any important bindings.
How can I make h and l scroll horizontally?
Best Answer
man less
tells us the following:It tells us to use
lesskey
to generate a lesskey file readingman lesskey
fills in the details. You can put the following in the lesskey input file (~/.lesskey
by default)Then run
lesskey
, and it will generate an output file (~/.less
by default) for you.As far as I can tell, you can't do character-by character horizontal scrolling.