31141 Commits

Author SHA1 Message Date
Paul Eggert
f3980d7cfa doc: fix date(1) synopses etc
Font problem reported by Michael Aramini via Alejandro Colomar
<https://bugs.gnu.org/80258>.  This patch also fixes some
longstanding confusion with date synopses.
* src/date.c (usage): Do not imply that only -u can be used with
MMDDhhmm..., and do not put misleading brackets around the latter.
2026-01-25 19:08:53 -08:00
Collin Funk
9cb06a7d13 tests: mktemp: export LC_ALL
* tests/mktemp/bad-unicode.sh: Run this test case using multiple
locales.
2026-01-25 21:19:45 +00:00
Pádraig Brady
ca68ab6c8a doc: support TAB as a delimiter between --option and description
* src/system.h (oputs_): Treat a single TAB as an option delimiter.
Some zh translations use this delimiter format.
2026-01-25 21:19:45 +00:00
Collin Funk
c3894e0723 tests: chgrp: allow a numeric user id to be printed
* tests/chgrp/from.sh: If 'id' cannot find a user name for user id 1,
expect the user id to be printed in the message of 'chgrp'.
Reported by Bruno Haible.
2026-01-24 15:06:51 -08:00
Pádraig Brady
ebb856730c tail: fix EINTR handling on older systems
tail(1) could fail with an "Interrupted system call"
diagnostic, on some systems like Centos 5 (Linux 2.6.18).
This was seen with tests/tail/overlay-headers.sh
which sends SIGCONT, which should not induce a failure.

* src/tail.c (tail_forever_inotify): Retry the poll()
upon receiving a non terminating signal, and the syscall
is not automatically restarted by the system.
* NEWS: Mention the bug fix.
Reported by Bruno Haible.
2026-01-24 20:00:32 +00:00
Collin Funk
ec77664a31 tests: avoid failures if 'ulimit -n' cannot set file descriptor limits
This fixes test failures seen on Haiku.

* tests/ls/recursive.sh: Run 'ls' even if ulimit fails.
* tests/split/r-chunk.sh: Run 'split' even if ulimit fails.
* tests/sort/sort-merge-fdlimit.sh: Skip test if 'ulimit -n' cannot set
file descriptor limits.
Reported by Bruno Haible.
2026-01-24 11:20:56 -08:00
Pádraig Brady
75c671415e tests: dd: avoid EPERM false failure on Solaris
* tests/dd/fail-ftruncate-fstat.sh: Also map the "Not owner"
error for EPERM seen on earlier Solaris 11 releases.
Reported by Bruno Haible.
2026-01-24 14:53:30 +00:00
Pádraig Brady
1361ade5c4 doc: nproc: mention OpenMP env vars in --help
* src/nproc.c (usage): Clarify the impact of 'OMP_NUM_THREADS'
and 'OMP_THREAD_LIMIT' in --help and the man page.
Also mention that nproc(1) will always return > 0.
Fixes https://bugs.gnu.org/80243
2026-01-24 13:49:03 +00:00
Pádraig Brady
3cec88e51e build: update to latest gnulib
* gnulib:
  - getdelim, getline: Don't replace these functions on glibc
  - selinux: fix link errors with termux
2026-01-24 13:03:51 +00:00
Bruno Haible
f748dc7133 tests: recognize SELinux support on Android
* init.cfg (require_selinux_): Also try to see if 'mount' lists the
selinuxfs.
2026-01-24 13:01:57 +00:00
Pádraig Brady
acf0acd0c9 tests: stty: avoid false failure if resizing terminal
* tests/stty/stty-row-col.sh: Skip the test if we detect terminal
resizing.  Also more robustly restore the original size.
2026-01-24 12:49:52 +00:00
Collin Funk
c351e1965d tests: readlink: avoid a false failure on Haiku
* tests/readlink/readlink-posix.sh: Allow the "A" in "Argument" to be
capitalized in return value of strerror (EINVAL).
2026-01-24 12:47:51 +00:00
Collin Funk
be0a448133 doc: NEWS: add a missing quotation mark
* NEWS: Add a closing quotation mark.
2026-01-23 20:15:57 -08:00
Pádraig Brady
bdf53cc685 tests: usage_vs_refs.sh: fix false failure with Alpine
* tests/misc/usage_vs_refs.sh: Fix missing escape on literal {,
required by busybox grep.
Reported by Bruno Haible.
2026-01-23 22:32:20 +00:00
Egmont Koblinger
25fccc7c46 doc: dir,vdir: add dircolors(1) reference to man pages
* man/dir.x: Add dircolors(1) to "SEE ALSO" section.
* man/vdir.x: Likewise.
2026-01-22 16:27:13 +00:00
Pádraig Brady
115a600100 doc: dir,vdir: fix anchor refs from --help
* src/system.h (oputs_): Map from dir,vdir to ls.
2026-01-22 16:23:41 +00:00
Egmont Koblinger
b76c1539ad doc: stat: fix highlighting of --format
* src/stat.c (usage): Add missing comma after -c.
2026-01-22 16:15:26 +00:00
Pádraig Brady
343cae4aed doc: NEWS: minor adjustments
* NEWS: Fix typos, and move item to more appropriate section.
2026-01-22 16:13:26 +00:00
Pádraig Brady
49420ca7d9 doc: pr: fix --help output output
* src/pr.c (usage): Use consistent alignment with -J,
and highlight --pages using oputs().
2026-01-22 13:00:38 +00:00
Pádraig Brady
eaf38a2412 doc: help2man: handle leading '+' in options
* man/help2man: Fix indentation of options with leading '+'.
2026-01-22 12:45:13 +00:00
Pádraig Brady
58ba9580e7 tests: fix false failure with pr -COLS
* tests/misc/usage_vs_getopt.sh: Fix false failure induced
by commit v9.9-239-ga06f0cf67
2026-01-22 11:56:50 +00:00
Pádraig Brady
87219034b7 doc: use TERM=dumb rather than HELP_NO_MARKUP to disable markup
This is a more standard mechanism to disable markup.

* src/system.h (oputs_): Logic change to honor TERM=dumb,
rather than HELP_NO_MARKUP=something.
* doc/coreutils.texi: Adjust the description for --help.
* man/local.mk: Ensure TERM is set to something,
so that man pages have links included.
* man/viewman: Just honor users $TERM.
* tests/misc/getopt_vs_usage.sh: Remove env var complication,
as TERM is unset automatically.
* tests/misc/usage_vs_refs.sh: Likewise.
* NEWS: Adjust the change in behavior note.
2026-01-22 11:42:47 +00:00
Pádraig Brady
bdc45990c7 tests: avoid false failure with non standard path
* tests/misc/usage_vs_refs.sh: Properly quote arguments
to avoid false failure with paths containing spaces etc.
2026-01-21 19:30:21 +00:00
Pádraig Brady
3e57f08e36 tests: avoid infinite loop in dd failure edge case
* tests/tee/tee.sh: If dd failed, then tee would spin
writing to the fifo forever, so add a timeout protection.
This was noticed with `export LD_PRELOAD=libasan.so.8`
with a non ASAN build, which induced a failure in dd invocations.
2026-01-21 19:00:03 +00:00
Pádraig Brady
f9eebda93c tests: avoid false failure with sanitizer builds
* init.cfg (sanitizer_build_): Add a helper to detect if a program
is built against a sanitizer.
* tests/df/no-mtab-status-masked-proc.sh: Skip if a sanitizer build.
2026-01-21 17:49:39 +00:00
Pádraig Brady
28c29d103e stat,tail: sync with latest Linux file systems
* src/stat.c (human_fstype): Add "guest-memfd".
* NEWS: Mention the improvement.
2026-01-21 16:29:03 +00:00
Pádraig Brady
92df52d791 tests: avoid false failure on setgid dir
* tests/misc/mknod.sh: Skip a portion of the test
in the edge case of setgid directories.
2026-01-21 16:06:51 +00:00
Pádraig Brady
dfeb32f6e2 ls: --hyperlink: switch to more standard delimiters
* src/ls.c (quote_name): Use ST (ESC \) rather than BEL,
as that's the only terminator mentioned in at least
ECMA-48, DEC STD 070, and EK-VT520-RM.
* NEWS: Mention the change in behavior.
* tests/ls/hyperlink.sh: Adjust accordingly.

Suggested by Egmont Koblinger.
2026-01-21 14:05:48 +00:00
Pádraig Brady
77e6b5d8f8 tests: ensure there is an anchor for each --help option
* tests/misc/usage_vs_refs.sh: A new test to correlation options
listed in --help, and anchors referenced in the texinfo (html) manual.
* tests/local.mk: Add the new test.
2026-01-21 14:05:48 +00:00
Pádraig Brady
7dfe08316d doc: NEWS: describe the --help markup configuration options
* NEWS: Mention build and runtime config options.
2026-01-21 14:05:48 +00:00
Pádraig Brady
d6a81caafc doc: adjust --help hyperlinks to more standard format
* src/system.h (oputs_): Use ST rather than BEL.
2026-01-21 13:51:58 +00:00
Pádraig Brady
2753931590 doc: add commentary on details of --help references
* src/system.h: Mention why we don't bother with (the overhead of)
hostnames in these URLs, and why --help,--version link are special.
2026-01-21 13:51:58 +00:00
Pádraig Brady
49cabb6845 doc: cp: group related -HLP descriptions
* src/cp (usage): The -HLP options are close
in functionality and close alphabetically, so describe together.
* doc/coreutils.texi (cp invocation): Likewise.
2026-01-21 13:51:58 +00:00
Pádraig Brady
c666aa7461 doc: cp: document --keep-directory-symlink in correct location
* src/cp.c (usage): Move to alphabetically in list.
* doc/coreutils.texi (mv invocation): Move description from here ...
(cp invocation): ... to here.
2026-01-21 13:51:58 +00:00
Pádraig Brady
af61d818f8 doc: ls: document --block-size in the manual
* doc/coreutils.texi (ls invocation): Document --block-size
2026-01-21 13:51:58 +00:00
Pádraig Brady
9a10b354ec doc: who: document --users in manual
* doc/coreutils.texi (who invocation): Mention that --users
is equivalent to -u.
* src/who.c (usage): Mention -u shows idle time.
2026-01-21 13:51:58 +00:00
Pádraig Brady
1d1539a529 doc: id: document -a in manual
* doc/coreutils.texi (id invocation): Mention this option is ignored.
2026-01-21 13:51:58 +00:00
Pádraig Brady
a06f0cf67e doc: more indexing fixes in manual
* doc/coreutils.texi: Add missing anchors.
* src/pr.c (Usage): Adjust to use -COLS, to avoid a clash
with the additional anchor added to the manual.
Also markup the --columns option as done for other options.
* tests/split/line-bytes.sh: Also fix --lines-bytes typo here.
2026-01-21 13:51:58 +00:00
Egmont Koblinger
5de8835672 doc: tty: fix indexing in texinfo
* doc/coreutils.texi: Fix recently introduced typo.
* THANKS.in: Remove as now committed to the repo.
2026-01-21 13:51:58 +00:00
Pádraig Brady
7426643f39 doc: make legacy digest utility --help reference cksum nodes
* src/system.h (oputs_): Map md5sum etc. to cksum urls,
as we only have cksum anchors in the manual to avoid
creating anchors for all of the legacy digest utilities.
2026-01-21 13:51:58 +00:00
Pádraig Brady
1e72a54ca7 doc: tweak tests to avoid false failure with --help
* tests/df/df-output.sh: Use a more relaxed match.
* tests/du/inodes.sh: Likewise.
2026-01-21 13:51:40 +00:00
Pádraig Brady
2dad24adc0 doc: all: use option highlighting and more standard alignment
Adjust all utils to:
  - Have a separate translation per option
  - Use either oputs() or oprintf(), instead of fputs() or printf().
  - Use more standard alignment as discussed in previous commits.
  - Various tweaks to descriptions.
2026-01-21 13:51:40 +00:00
Pádraig Brady
0f5ab6cb8b doc: readlink: improve option ordering in texinfo
* doc/coreutils.texi (readlink invocation): Order -q,-s alphabetically.
2026-01-21 13:51:40 +00:00
Pádraig Brady
1cbfdce425 doc: chcon: use more standard -HLP desciptions
* src/chcon.c (usage): Use emit_symlink_recurse_options ("-P").
2026-01-21 13:51:40 +00:00
Pádraig Brady
e73d594374 doc: highlight -HLP options
* src/system.h (emit_symlink_recurse_options): Highlight -HLP,
for chmod, chcon etc.
2026-01-21 13:51:40 +00:00
Pádraig Brady
e9d398e221 doc: put --help and --version descriptions on separate line
* src/system.h: This aligns the output with the option
description format used in most commands
2026-01-21 13:51:39 +00:00
Pádraig Brady
cab15fc4ef doc: ls: put option description on separate line to option
* src/ls.c (usage): This is less constrained when writing comments,
and more consistent in output alignment.  There is less delineation
between options and descripts, but given options are highlighted
by default now, this is a more appropriate format to use.
Note consistently showing description on the line following the option,
avoids any issue with the user needing to visually line up
the option with a description far to the right.
Note this format more closely aligns with that used in man pages.
2026-01-21 13:51:39 +00:00
Pádraig Brady
3950891eaa doc: viewman: a new helper to quickly view formatted man pages
Use like: man/viewman ls

* man/viewman: Generate man page on the fly, and view.
2026-01-21 13:51:39 +00:00
Pádraig Brady
5939e67704 doc: help2man: account for undisplayed markup in indenting calculations
* man/help2man: This is significant with the indented line
following the dd bs=BYTES "option" at least.
2026-01-21 13:51:39 +00:00
Pádraig Brady
ed91d9a218 doc: help2man: convert all hyperlinks, not just ones in --options
* man/help2man: Make the (--?) part of the match optional.
Note we still extract the dashes, to support the existing
option matching logic in help2man.
2026-01-21 13:51:39 +00:00