Coloured man pages!

Are you bored from viewing monochrome(black & white) man pages?  Let's make the world a little bit colorful.

coloured man page
Colored man pages allow for a clearer presentation and easier digestion of the content. Let's see how to do it.

Method 1:

Open a terminal and type the following codes:

sudo apt-get install most

export PAGER="most"
That's it now open your favorite man pages and you will be awestruck to see colored man pages.

Method 2: 

This method has the advantage that less has a bigger feature set than most, and is the default for viewing man pages.
Add the following to a shell configuration file. All that needs to be done is to export bold and underline values of termcap. Adding the values to the ~/.bashrc will make sure that they are always used:
# Less Colors for Man Pages
export LESS_TERMCAP_mb=$'\E[01;31m' # begin blinking
export LESS_TERMCAP_md=$'\E[01;38;5;74m' # begin bold
export LESS_TERMCAP_me=$'\E[0m' # end mode
export LESS_TERMCAP_se=$'\E[0m' # end standout-mode
export LESS_TERMCAP_so=$'\E[38;5;246m' # begin standout-mode - info box
export LESS_TERMCAP_ue=$'\E[0m' # end underline
export LESS_TERMCAP_us=$'\E[04;38;5;146m' # begin underline 
And source the ~/.bashrc to have it work:
source ~/.bashrc

Popular posts from this blog


How to setup a wifi-hotspot in Ubuntu: The terminal way.

How to install OpenVAS 7 in Ubuntu