bug#10281: change in behavior of du with multiple arguments (commit
From:
Voelker, Bernhard
Subject:
bug#10281: change in behavior of du with multiple arguments (commit
Date:
Thu, 15 Dec 2011 09:30:36 +0100
Bob Proulx wrote:
> Alan Curry wrote:
> > Why not let the -c total be correct *and* the -s individual numbers also be
> > correct for the names they are next to? Like this:
> >
> > $ mkdir a b ; echo hello > a/a ; ln a/a b/b ; du -cs a b
> > 8 a
> > 8 b
> > 12 total
> >
> > The fact that the numbers on the left don't add up means there is less
> > redundancy in the output. Each number actually tells me something you can't
> > derive from the others. There is higher information content. This is good,
> > not bad.
>
> I like this idea. +1
I also like the idea, but is there already consensus on the starting
question: what to do with - I call it - stacked arguments?
$ mkdir -p d/d
$ echo foo > d/f
$ echo bar > d/d/g
$ ln d/f d/d/f
$ du -s d d/d
I omitted the result, but I think Paul's question
is the important one:
"how much disk space I'll reclaim by removing ..."
Therefore, and from a user's perspective, I'd expect
du to count d/d again for the sum of the first argument d.
Is this covered by the proposal?
What would be the output for the above example?
Have a nice day,
Berny