NAME
terminal-colors.d - configure output colorization for various utilitiesSYNOPSIS
/etc/terminal-colors.d/ [[name][@term].][type]DESCRIPTION
Files in this directory determine the default behavior for utilities when coloring output.Turns off output colorization for all
compatible utilities.
Turns on output colorization; any matching
disable files are ignored.
Specifies colors used for output. The file
format may be specific to the utility, the default format is described
below.
DEFAULT SCHEME FILES FORMAT
The following statement is recognized:Color names
black, blink, blue, bold, brown, cyan, darkgray, gray, green, halfbright, lightblue, lightcyan, lightgray, lightgreen, lightmagenta, lightred, magenta, red, reset, reverse, and yellow.ANSI color sequences
The color sequences are composed of sequences of numbers separated by semicolons. The most common codes are:0 | to restore default color |
1 | for brighter colors |
4 | for underlined text |
5 | for flashing text |
30 | for black foreground |
31 | for red foreground |
32 | for green foreground |
33 | for yellow (or brown) foreground |
34 | for blue foreground |
35 | for purple foreground |
36 | for cyan foreground |
37 | for white (or gray) foreground |
40 | for black background |
41 | for red background |
42 | for green background |
43 | for yellow (or brown) background |
44 | for blue background |
45 | for purple background |
46 | for cyan background |
47 | for white (or gray) background |
Escape sequences
To specify control or blank characters in the color sequences, C-style \-escaped notation can be used:\a | Bell (ASCII 7) |
\b | Backspace (ASCII 8) |
\e | Escape (ASCII 27) |
\f | Form feed (ASCII 12) |
\n | Newline (ASCII 10) |
\r | Carriage Return (ASCII 13) |
\t | Tab (ASCII 9) |
\v | Vertical Tab (ASCII 11) |
\? | Delete (ASCII 127) |
\_ | Space |
\\ | Backslash (\) |
\^ | Caret (^) |
\# | Hash mark (#) |
Comments
Lines where the first non-blank character is a # (hash) are ignored. Any other use of the hash character is not interpreted as introducing a comment.ENVIRONMENT
TERMINAL_COLORS_DEBUG=allenables debug output.
FILES
$XDG_CONFIG_HOME/terminal-colors.dEXAMPLE
Disable colors for all compatible utilities:COMPATIBILITY
The terminal-colors.d functionality is currently supported by all util-linux utilities which provides colorized output. For more details always see the COLORS section in the man page for the utility.REPORTING BUGS
For bug reports, use the issue tracker at <https://github.com/util-linux/util-linux/issues>.AVAILABILITY
terminal-colors.d is part of the util-linux package which can be downloaded from Linux Kernel Archive <https://www.kernel.org/pub/linux/utils/util-linux/>.2022-05-11 | util-linux 2.38.1 |