Re: Clarifying behavior of diff --stat
- From
Jeff King <peff@peff.net>
- Date
- Jun 9, 2017, 05:21 UTC
- Message-ID
- <20170609052121.f5fudcq6yz5d3r56@sigill.intra.peff.net>
- In-Reply-To
- <CAJZjrdUHm2JAGsjurcGxONQomAtvV_GMgzqb0pPEovHSySd=KA@mail.gmail.com>
On Thu, Jun 08, 2017 at 07:10:00AM -0400, Samuel Lijin wrote:
> I noticed when answering a StackOverflow question that apparently > --stat modifies the raw diff itself, instead of just adding a diffstat > to the output. In the linux kernel:
Sort of. Using "--stat" implies "-r", since it only deals with the actual blobs and would have nothing to show for tree entries.
And since recursive-ness is global to the whole diff, not just one output format, the --raw output becomes recursive, too.
> Is this intentional? And is there a way to generate a raw version of > the extended stat without using --stat?
Try "git diff-tree --raw -r".
-Peff