On 2026-08-30 07:58, Tim Landscheidt wrote:
So it would be nice if that format could be documented so
that it could be relied upon.
While looking into this, I noticed that POSIX
(https://pubs.opengroup.org/onlinepubs/9799919799/utilities/uniq.html)
It's not specified the way you suggest, for the same reason POSIX doesn't do so. A separate
section of POSIX[1] says that a utilities-spec format like ""%d %s" allows
spaces in front of the %d and allows any white space to separate the %d from the %s. Portable
programs are not supposed to care about the differences. Documentation typically does not go
into such details, for brevity. If we to make this clearer, we should do so in the manual the
same way that POSIX does, given that the issue affects many coreutils programs, not just wc.
[1]:
https://pubs.opengroup.org/onlinepubs/9799919799/basedefs/V1_chap05.html#tag_05