Colored less output

Published 07-26-2011 00:00:00

To colorize the output of less, use the GNU Source-highlight tool.

Install Debian package:

$ sudo apt-get install source-highlight

Add this to your shell configuration file:

export LESSOPEN="| /usr/share/source-highlight/src-hilite-lesspipe.sh %s"
export LESS=' -R '