tmux man-page search highlighting

Based on Less Colors For Man Pages by Gen2ly, here is my man page and how to do it:

Preview

This is a shell, not a web page !
Custom search highlighting in man page

How to

  1. (optional) I’m using Tomorrow theme for Konsole/Yakuake ;
  2. Edit your ~/.bashrc ~/.zshrc, etc. to add :

    # Colored man pages: http://linuxtidbits.wordpress.com/2009/03/23/less-colors-for-man-pages/
    # 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;016m\E[48;5;220m'    # begin standout-mode - info box
    export LESS_TERMCAP_ue=$'\E[0m'           # end underline
    export LESS_TERMCAP_us=$'\E[04;38;5;146m' # begin underline
    
  3. Reload your config and try a man page search :

    . ~/.bashrc && man ls
    

Leave a Comment