Currently I have this in my "~/.profile":

export PAGER='env TERM=fox less'

However I just realized that this only works with "man", and not if you do something like this:

less /etc/DIR_COLORS

to try to fix this, I created a "~/.lesskey" file:

LESS = -i
TERM = fox

and installed by running "lesskey". Now when I run "less" the "LESS" variable is recognized, but not the "TERM" variable. How can I have less use a custom terminal?


If you want this for all your commands, just put


in your .profile. If you need it only for less, you could define an alias

alias less='TERM=fox less'

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.