TERMINAL-COLORS.D(5)
๐ธ TERMINAL-COLORS.D โ the file format page, bestie edition ๐
okay so this is the terminal-colors.d manual, section 5 (File formats). It's the whole vibe of how your terminal decides what's pretty and what's plain. No cap.
โจ NAME โจ
terminal-colors.d โ configure output colorization for various utilities ๐จ
โจ SYNOPSIS โจ
/etc/terminal-colors.d/[name.|[name]@term.]type
โจ DESCRIPTION โจ
So the files chilling in this directory? They decide the default behavior for utilities when they're coloring output. That's literally their whole job.
The name is a utility name. It's optional, and when none is specified then the file is used for all unspecified utilities. she's a universal queen ๐
The term is a terminal identifier โ aka the TERM environment variable. The terminal identifier is optional too, and when none is specified then the file is used for all unspecified terminals.
The type is a file type. Here are the supported file types, and yes you need to know all of them:
disableโ Turns off output colorization for all compatible utilities. Also peep theNO_COLORenvironment variable below ๐enableโ Turns on output colorization; any matchingdisablefiles are ignored.schemeโ Specifies colors used for output. The file format may be specific to the utility, and the default format is described below.
Now here's the drama: if there are more files that match for a utility, then the file with the more specific filename wins. For example, the filename @xterm.scheme has less priority than dmesg@xterm.scheme. The lowest priority are those files without a utility name and terminal identifier (e.g., "disable"). Most specific girlie takes the crown.
And the user-specific $XDG_CONFIG_HOME/terminal-colors.d or $HOME/.config/terminal-colors.d overrides the global setting. Your personal config ate, fr fr.
๐ DEFAULT SCHEME FILES FORMAT ๐
The following statement is recognized:
name color-sequence
The name is a logical name for the color sequence (for example: error). The names are specific to the utilities. For more details always see the COLORS section in the man page for the utility.
The color-sequence can be a color name, an ANSI color sequence, or an escape sequence. Pick your fighter ๐
๐ Color names
Valid color names are: 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
An ANSI color sequence is composed of sequences of numbers separated by semicolons. The most common codes are:
0โ to restore default color1โ for brighter colors4โ for underlined text5โ for flashing text30โ for black foreground31โ for red foreground32โ for green foreground33โ for yellow (or brown) foreground34โ for blue foreground35โ for purple foreground36โ for cyan foreground37โ for white (or gray) foreground40โ for black background41โ for red background42โ for green background43โ for yellow (or brown) background44โ for blue background45โ for purple background46โ for cyan background47โ for white (or gray) background
For example, to use a red background for alert messages in the output of dmesg(1), use:
echo 'alert 37;41' >> /etc/terminal-colors.d/dmesg.scheme
slay. ๐ฅ
๐ Escape sequences
An escape sequence is needed to enter a space, backslash, caret, or any control character anywhere in a string, as well as a hash mark as the first character. These C-style backslash-escapes 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. So don't get cute with it.
๐ ENVIRONMENT ๐
TERMINAL_COLORS_DEBUG=allโ enables debug output.NO_COLORโ if defined, this disables output colorization unless explicitly enabled by a command-line option. Seehttps://no-color.org/for more details. Supported since util-linux version2.41.
๐ฆ FILES ๐ฆ
$XDG_CONFIG_HOME/terminal-colors.d$HOME/.config/terminal-colors.d/etc/terminal-colors.d
โญ EXAMPLES โญ
Disable colors for all compatible utilities:
touch /etc/terminal-colors.d/disable
Disable colors for all compatible utils on a vt100 terminal:
touch /etc/terminal-colors.d/@vt100.disable
Disable colors for all compatible utils except dmesg(1):
touch /etc/terminal-colors.d/disable
touch /etc/terminal-colors.d/dmesg.enable
the enable file really said "not her, she's exempt" ๐
๐ COMPATIBILITY ๐
The terminal-colors.d functionality is currently supported by all util-linux utilities which provide 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 <https://github.com/util-linux/util-linux/issues>.
bestie if something's broken, tell the maintainers, don't just suffer in silence ๐ญ
๐ซถ 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/>.
and that's the whole page, bestie โ no skips, no cuts, every flag and every escape sequence accounted for. This one's from util-linux 2.42.4, dated 2026-09-21. go be colorful ๐โจ๐
๐ฆ where this page comes from
- arch rolling: util-linux 2.42.4-1 ยท BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause-UC AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND ISC AND LGPL-2.1-or-later AND LicenseRef-PublicDomain
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms