You can explicitly use colors in manpages. I saw this in the apt manpage of Ubuntu recently, which, for some reason, uses blue text in one place:

https://movq.de/v/de5ab72016/s.png

Makes little sense to me. I’m glad that most manpages don’t do this. I wouldn’t want unicorn vomit all over the place.

Using colors can be done using the low level commands \m and \M:

.TH foo_program 3
\m[blue]I'm blue\m[], da ba dee.
\m[red]\M[yellow]I'm red on yellow.\m[]\M[]
    This is quite horrible.

https://movq.de/v/394282ec75/s.png

⤋ Read More

Ah, so apparently they don’t like writing manpages anymore and instead use XML:

https://salsa.debian.org/apt-team/apt/-/blob/main/doc/apt.8.xml

And then they use XSLT on top and what not:

https://salsa.debian.org/apt-team/apt/-/blob/main/doc/manpage-style.xsl.cmake.in

It’s not even explicitly blue:

https://salsa.debian.org/apt-team/apt/-/blob/main/doc/apt.ent?ref_type=heads#L17

Abstractions upon abstractions upon abstractions.

⤋ Read More

Participate

Login or Register to join in on this yarn.