-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.less_termcap
67 lines (62 loc) · 3.03 KB
/
.less_termcap
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
## This file makes less to colorise output like most ##
## It gets sourced in ~/.bash_aliases ##
# tput color codes -- more readable way than ANSI escape codes
# https://linux.101hacks.com/ps1-examples/prompt-color-using-tput/
# 0 – Black
# 1 – Red
# 2 – Green
# 3 – Yellow
# 4 – Blue
# 5 – Magenta
# 6 – Cyan
# 7 – White
# Colors from https://unix.stackexchange.com/questions/119/colors-in-man-pages?utm_medium=organic&utm_source=google_rich_qa&utm_campaign=google_rich_qa
#export LESS_TERMCAP_mb=$(tput bold; tput setaf 2) # green
#export LESS_TERMCAP_md=$(tput bold; tput setaf 6) # cyan
#export LESS_TERMCAP_me=$(tput sgr0)
#export LESS_TERMCAP_so=$(tput bold; tput setaf 3; tput setab 4) # yellow on blue
#export LESS_TERMCAP_se=$(tput rmso; tput sgr0)
#export LESS_TERMCAP_us=$(tput smul; tput bold; tput setaf 7) # white
#export LESS_TERMCAP_ue=$(tput rmul; tput sgr0)
#export LESS_TERMCAP_mr=$(tput rev)
#export LESS_TERMCAP_mh=$(tput dim)
#export LESS_TERMCAP_ZN=$(tput ssubm)
#export LESS_TERMCAP_ZV=$(tput rsubm)
#export LESS_TERMCAP_ZO=$(tput ssupm)
#export LESS_TERMCAP_ZW=$(tput rsupm)
#export GROFF_NO_SGR=1 # For Konsole and Gnome-terminal
## Mostly most like -- combination similar to the one that MOST pager uses
# For the win, combine with export MANPAGER='less -s -M +Gg'
export LESS_TERMCAP_mb=$(tput bold; tput setaf 6) # cyan
export LESS_TERMCAP_md=$(tput bold; tput setaf 1) # red
export LESS_TERMCAP_me=$(tput sgr0)
export LESS_TERMCAP_so=$(tput bold; tput setaf 3; tput setab 4) # yellow on blue
export LESS_TERMCAP_se=$(tput rmso; tput sgr0)
export LESS_TERMCAP_us=$(tput smul; tput bold; tput setaf 2) # green
export LESS_TERMCAP_ue=$(tput rmul; tput sgr0)
export LESS_TERMCAP_mr=$(tput rev)
export LESS_TERMCAP_mh=$(tput dim)
export LESS_TERMCAP_ZN=$(tput ssubm)
export LESS_TERMCAP_ZV=$(tput rsubm)
export LESS_TERMCAP_ZO=$(tput ssupm)
export LESS_TERMCAP_ZW=$(tput rsupm)
export GROFF_NO_SGR=1 # For Konsole and Gnome-terminal
# Have less display colours -- alternative colors
# from: https://wiki.archlinux.org/index.php/Color_output_in_console#man
#export LESS_TERMCAP_mb=$'\e[1;31m' # begin bold
#export LESS_TERMCAP_md=$'\e[1;33m' # begin blink
#export LESS_TERMCAP_so=$'\e[01;44;37m' # begin reverse video
#export LESS_TERMCAP_us=$'\e[01;37m' # begin underline
#export LESS_TERMCAP_me=$'\e[0m' # reset bold/blink
#export LESS_TERMCAP_se=$'\e[0m' # reset reverse video
#export LESS_TERMCAP_ue=$'\e[0m' # reset underline
#export GROFF_NO_SGR=1 # for konsole and gnome-terminal
## More colors
# export LESS_TERMCAP_mb=$'\E[1;31m' # begin bold
# export LESS_TERMCAP_md=$'\E[1;36m' # begin blink
# export LESS_TERMCAP_me=$'\E[0m' # reset bold/blink
# export LESS_TERMCAP_so=$'\E[01;44;33m' # begin reverse video
# export LESS_TERMCAP_se=$'\E[0m' # reset reverse video
# export LESS_TERMCAP_us=$'\E[1;32m' # begin underline
# export LESS_TERMCAP_ue=$'\E[0m' # reset underline
# export GROFF_NO_SGR=1 # for konsole and gnome-terminal