]> git.ipfire.org Git - thirdparty/coreutils.git/commit
doc: ls: support styling and links in --help output
authorPádraig Brady <P@draigBrady.com>
Tue, 25 Nov 2025 13:40:32 +0000 (13:40 +0000)
committerPádraig Brady <P@draigBrady.com>
Wed, 21 Jan 2026 13:51:39 +0000 (13:51 +0000)
commitd5e15b2f295353b2119ee58e9d10ec2135d3e7d6
treec514080312568f69563e5e1589a316d13ad34cf0
parent88760f9c105de45104f3ff2f3a5e501b847b53d5
doc: ls: support styling and links in --help output

* src/ls.c (oputs): A new function that wraps puts(),
but also highlights the --option-text portion, and
adds links to the appropriate part of the online manual.
(usage): Call oputs() rather than puts().
* doc/coreutils.texi (--help): Document new HELP_NO_MARKUP env var,
which can be used in the edge case one wants to suppress ansi escapes.
* tests/misc/getopt_vs_usage.sh: Use HELP_NO_MARKUP to ensure the
test continues to pass.
doc/coreutils.texi
src/ls.c
tests/misc/getopt_vs_usage.sh