Thread (3 messages) flat view 3 messages, 3 authors, 2016-06-15

Re: [PATCH] diff-options: add --stat

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:42:23

Junio C Hamano [off-list ref] writes:
I wonder if you can also make this an independent option that
prepends diffstat in front of the patch, just like the way the
new flag --patch-with-raw flag prepends raw output in front of
the patch.
Clarification.

Traditionally, we had diff-raw and diff-patch formats.
We can think of --name-status and --name-only variants of
diff-raw (just like different --abbrev settings give different
visuals for diff-raw).  Until very recently, these were either-or
output formats, but for Cogito we added an option to show both.

We could reorganize the output format options to:

	- diff-raw and its name variants
	- diff-stat
        - diff-patch

and have (internally) three bools to specify which ones to
output, in the above order.  The recent --patch-with-raw would
flip bit #0 (show raw) and bit #2 (show patch) on.  It is very
likely that diff-stat followed by diff-patch would be a popular
format (that is what git-format-patch does), and it also is
conceivable that diff-raw with diff-stat but without diff-patch
might turn out to be useful for some people.

Also, I forgot to mention, but would it be useful to have a
diffstat to show --cc?  It is unclear, without much thinking,
what the numbers would mean, though...
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help