Subject: bug#10282: change in behavior of du with multiple arguments (commit efe53cc)

From: Paul Eggert <[email-masked]>
Date: Tue, 13 Dec 2011 12:09:42 -0800

On 12/13/11 09:16, Eric Blake wrote:
> Or maybe --count-links gains an optional argument, that says how to
> count links:
> 
> --count-links=none -> POSIX behavior (if POSIX requires elision across
> command line arguments
> --count-links=per-directory -> traditional behavior, resetting hash
> between command line arguments
> --count-links == --count-links=all -> count every file on every encounter

Yes, that was the sort of thing that I had in mind.  Though,
like Kamil, I hadn't thought that the per-directory argument was all that
useful, since one can simply invoke "du" multiple times to get that behavior.

Your earlier message suggests another option, which could be
--count-links=zero or something like that: it causes "du" to
output a "0 X" line for every entry that would otherwise be
elided because it's a duplicate.  Or perhaps we could make that
"-0 X" so that one can distinguish duplicates from true zero
entries.

Or perhaps it would be better to have a --count-links=mark option,
which causes du to output "+N X" for a duplicate link, where N is
the size, and the "+" marks it as a duplicate.

Just thinking out loud....  At any rate it doesn't sound like
it's high priority.