git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [PATCH] format-patch: use --compact-summary instead of --summary
@ 2018-03-16 20:06 Nguyễn Thái Ngọc Duy
  2018-03-16 21:41 ` Junio C Hamano
  0 siblings, 1 reply; 3+ messages in thread
From: Nguyễn Thái Ngọc Duy @ 2018-03-16 20:06 UTC (permalink / raw)
  To: git; +Cc: Nguyễn Thái Ngọc Duy

For reviewers, a couple fewer lines from diffstat (either cover letter
or patches) is a good thing because there's less to read.

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
---
 I realize that rename percentage is lost with this change. I just
 hope that nobody cares about that, or I'll have to implement rename
 percentage in --compact-summary too in order to move this patch
 forward.

 builtin/log.c                                 |  9 +++++---
 ...tach_--stdout_--suffix=.diff_initial..side |  7 +++---
 ...at-patch_--attach_--stdout_initial..master | 19 +++++++---------
 ...t-patch_--attach_--stdout_initial..master^ | 12 +++++-----
 ...rmat-patch_--attach_--stdout_initial..side |  7 +++---
 ..._--stdout_--numbered-files_initial..master | 19 +++++++---------
 ..._--subject-prefix=TESTCASE_initial..master | 19 +++++++---------
 ...at-patch_--inline_--stdout_initial..master | 19 +++++++---------
 ...t-patch_--inline_--stdout_initial..master^ | 12 +++++-----
 ...-patch_--inline_--stdout_initial..master^^ |  7 +++---
 ...rmat-patch_--inline_--stdout_initial..side |  7 +++---
 ...-stdout_--cover-letter_-n_initial..master^ | 22 ++++++++-----------
 ...tch_--stdout_--no-numbered_initial..master | 19 +++++++---------
 ...-patch_--stdout_--numbered_initial..master | 19 +++++++---------
 ...diff.format-patch_--stdout_initial..master | 19 +++++++---------
 ...iff.format-patch_--stdout_initial..master^ | 12 +++++-----
 .../diff.format-patch_--stdout_initial..side  |  7 +++---
 t/t4052-stat-output.sh                        |  4 ++--
 18 files changed, 103 insertions(+), 136 deletions(-)

diff --git a/builtin/log.c b/builtin/log.c
index 94ee177d56..c8e3be5de7 100644
--- a/builtin/log.c
+++ b/builtin/log.c
@@ -1062,7 +1062,8 @@ static void make_cover_letter(struct rev_info *rev, int use_stdout,
 		return;
 
 	memcpy(&opts, &rev->diffopt, sizeof(opts));
-	opts.output_format = DIFF_FORMAT_SUMMARY | DIFF_FORMAT_DIFFSTAT;
+	opts.output_format = DIFF_FORMAT_DIFFSTAT;
+	opts.flags.stat_with_summary = 1;
 	opts.stat_width = MAIL_DEFAULT_WRAP;
 
 	diff_setup_done(&opts);
@@ -1615,8 +1616,10 @@ int cmd_format_patch(int argc, const char **argv, const char *prefix)
 
 	if (!use_patch_format &&
 		(!rev.diffopt.output_format ||
-		 rev.diffopt.output_format == DIFF_FORMAT_PATCH))
-		rev.diffopt.output_format = DIFF_FORMAT_DIFFSTAT | DIFF_FORMAT_SUMMARY;
+		 rev.diffopt.output_format == DIFF_FORMAT_PATCH)) {
+		rev.diffopt.output_format = DIFF_FORMAT_DIFFSTAT;
+		rev.diffopt.flags.stat_with_summary = 1;
+	}
 	if (!rev.diffopt.stat_width)
 		rev.diffopt.stat_width = MAIL_DEFAULT_WRAP;
 
diff --git a/t/t4013/diff.format-patch_--attach_--stdout_--suffix=.diff_initial..side b/t/t4013/diff.format-patch_--attach_--stdout_--suffix=.diff_initial..side
index 547ca065a5..89ab87fb4e 100644
--- a/t/t4013/diff.format-patch_--attach_--stdout_--suffix=.diff_initial..side
+++ b/t/t4013/diff.format-patch_--attach_--stdout_--suffix=.diff_initial..side
@@ -12,11 +12,10 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--attach_--stdout_initial..master b/t/t4013/diff.format-patch_--attach_--stdout_initial..master
index 52fedc179e..48f284f1d9 100644
--- a/t/t4013/diff.format-patch_--attach_--stdout_initial..master
+++ b/t/t4013/diff.format-patch_--attach_--stdout_initial..master
@@ -14,11 +14,10 @@ Content-Transfer-Encoding: 8bit
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -73,10 +72,9 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -121,11 +119,10 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--attach_--stdout_initial..master^ b/t/t4013/diff.format-patch_--attach_--stdout_initial..master^
index 1c3cde251b..be6de1290a 100644
--- a/t/t4013/diff.format-patch_--attach_--stdout_initial..master^
+++ b/t/t4013/diff.format-patch_--attach_--stdout_initial..master^
@@ -14,11 +14,10 @@ Content-Transfer-Encoding: 8bit
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -73,10 +72,9 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--attach_--stdout_initial..side b/t/t4013/diff.format-patch_--attach_--stdout_initial..side
index 4717bd8313..c14f4c9011 100644
--- a/t/t4013/diff.format-patch_--attach_--stdout_initial..side
+++ b/t/t4013/diff.format-patch_--attach_--stdout_initial..side
@@ -12,11 +12,10 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--inline_--stdout_--numbered-files_initial..master b/t/t4013/diff.format-patch_--inline_--stdout_--numbered-files_initial..master
index 02c4db7ec5..d763a0b437 100644
--- a/t/t4013/diff.format-patch_--inline_--stdout_--numbered-files_initial..master
+++ b/t/t4013/diff.format-patch_--inline_--stdout_--numbered-files_initial..master
@@ -14,11 +14,10 @@ Content-Transfer-Encoding: 8bit
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -73,10 +72,9 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -121,11 +119,10 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--inline_--stdout_--subject-prefix=TESTCASE_initial..master b/t/t4013/diff.format-patch_--inline_--stdout_--subject-prefix=TESTCASE_initial..master
index c7677c5951..441a7d8a9d 100644
--- a/t/t4013/diff.format-patch_--inline_--stdout_--subject-prefix=TESTCASE_initial..master
+++ b/t/t4013/diff.format-patch_--inline_--stdout_--subject-prefix=TESTCASE_initial..master
@@ -14,11 +14,10 @@ Content-Transfer-Encoding: 8bit
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -73,10 +72,9 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -121,11 +119,10 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--inline_--stdout_initial..master b/t/t4013/diff.format-patch_--inline_--stdout_initial..master
index 5b3e34e2c0..0eb5b3aa3b 100644
--- a/t/t4013/diff.format-patch_--inline_--stdout_initial..master
+++ b/t/t4013/diff.format-patch_--inline_--stdout_initial..master
@@ -14,11 +14,10 @@ Content-Transfer-Encoding: 8bit
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -73,10 +72,9 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -121,11 +119,10 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--inline_--stdout_initial..master^ b/t/t4013/diff.format-patch_--inline_--stdout_initial..master^
index d13f8a8128..2d019707e2 100644
--- a/t/t4013/diff.format-patch_--inline_--stdout_initial..master^
+++ b/t/t4013/diff.format-patch_--inline_--stdout_initial..master^
@@ -14,11 +14,10 @@ Content-Transfer-Encoding: 8bit
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 
 --------------g-i-t--v-e-r-s-i-o-n
@@ -73,10 +72,9 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--inline_--stdout_initial..master^^ b/t/t4013/diff.format-patch_--inline_--stdout_initial..master^^
index caec5537de..1aa57f21d6 100644
--- a/t/t4013/diff.format-patch_--inline_--stdout_initial..master^^
+++ b/t/t4013/diff.format-patch_--inline_--stdout_initial..master^^
@@ -14,11 +14,10 @@ Content-Transfer-Encoding: 8bit
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--inline_--stdout_initial..side b/t/t4013/diff.format-patch_--inline_--stdout_initial..side
index d3a6762130..844b348eee 100644
--- a/t/t4013/diff.format-patch_--inline_--stdout_initial..side
+++ b/t/t4013/diff.format-patch_--inline_--stdout_initial..side
@@ -12,11 +12,10 @@ Content-Type: text/plain; charset=UTF-8; format=fixed
 Content-Transfer-Encoding: 8bit
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 
 --------------g-i-t--v-e-r-s-i-o-n
diff --git a/t/t4013/diff.format-patch_--stdout_--cover-letter_-n_initial..master^ b/t/t4013/diff.format-patch_--stdout_--cover-letter_-n_initial..master^
index 244d964fc6..9f4525a60d 100644
--- a/t/t4013/diff.format-patch_--stdout_--cover-letter_-n_initial..master^
+++ b/t/t4013/diff.format-patch_--stdout_--cover-letter_-n_initial..master^
@@ -10,13 +10,11 @@ A U Thor (2):
   Second
   Third
 
- dir/sub | 4 ++++
- file0   | 3 +++
- file1   | 3 +++
- file2   | 3 ---
+ dir/sub      | 4 ++++
+ file0        | 3 +++
+ file1 (new)  | 3 +++
+ file2 (gone) | 3 ---
  4 files changed, 10 insertions(+), 3 deletions(-)
- create mode 100644 file1
- delete mode 100644 file2
 
 -- 
 g-i-t--v-e-r-s-i-o-n
@@ -28,11 +26,10 @@ Subject: [DIFFERENT_PREFIX 1/2] Second
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..8422d40 100644
@@ -73,10 +70,9 @@ Date: Mon, 26 Jun 2006 00:02:00 +0000
 Subject: [DIFFERENT_PREFIX 2/2] Third
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 diff --git a/dir/sub b/dir/sub
 index 8422d40..cead32e 100644
diff --git a/t/t4013/diff.format-patch_--stdout_--no-numbered_initial..master b/t/t4013/diff.format-patch_--stdout_--no-numbered_initial..master
index bfc287a147..c102104f70 100644
--- a/t/t4013/diff.format-patch_--stdout_--no-numbered_initial..master
+++ b/t/t4013/diff.format-patch_--stdout_--no-numbered_initial..master
@@ -6,11 +6,10 @@ Subject: [PATCH] Second
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..8422d40 100644
@@ -51,10 +50,9 @@ Date: Mon, 26 Jun 2006 00:02:00 +0000
 Subject: [PATCH] Third
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 diff --git a/dir/sub b/dir/sub
 index 8422d40..cead32e 100644
@@ -85,11 +83,10 @@ Date: Mon, 26 Jun 2006 00:03:00 +0000
 Subject: [PATCH] Side
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..7289e35 100644
diff --git a/t/t4013/diff.format-patch_--stdout_--numbered_initial..master b/t/t4013/diff.format-patch_--stdout_--numbered_initial..master
index 568f6f584e..f29efe555e 100644
--- a/t/t4013/diff.format-patch_--stdout_--numbered_initial..master
+++ b/t/t4013/diff.format-patch_--stdout_--numbered_initial..master
@@ -6,11 +6,10 @@ Subject: [PATCH 1/3] Second
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..8422d40 100644
@@ -51,10 +50,9 @@ Date: Mon, 26 Jun 2006 00:02:00 +0000
 Subject: [PATCH 2/3] Third
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 diff --git a/dir/sub b/dir/sub
 index 8422d40..cead32e 100644
@@ -85,11 +83,10 @@ Date: Mon, 26 Jun 2006 00:03:00 +0000
 Subject: [PATCH 3/3] Side
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..7289e35 100644
diff --git a/t/t4013/diff.format-patch_--stdout_initial..master b/t/t4013/diff.format-patch_--stdout_initial..master
index 5f0352f9f7..febe8c4390 100644
--- a/t/t4013/diff.format-patch_--stdout_initial..master
+++ b/t/t4013/diff.format-patch_--stdout_initial..master
@@ -6,11 +6,10 @@ Subject: [PATCH 1/3] Second
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..8422d40 100644
@@ -51,10 +50,9 @@ Date: Mon, 26 Jun 2006 00:02:00 +0000
 Subject: [PATCH 2/3] Third
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 diff --git a/dir/sub b/dir/sub
 index 8422d40..cead32e 100644
@@ -85,11 +83,10 @@ Date: Mon, 26 Jun 2006 00:03:00 +0000
 Subject: [PATCH 3/3] Side
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..7289e35 100644
diff --git a/t/t4013/diff.format-patch_--stdout_initial..master^ b/t/t4013/diff.format-patch_--stdout_initial..master^
index 2ae454d807..ade0790a44 100644
--- a/t/t4013/diff.format-patch_--stdout_initial..master^
+++ b/t/t4013/diff.format-patch_--stdout_initial..master^
@@ -6,11 +6,10 @@ Subject: [PATCH 1/2] Second
 
 This is the second commit.
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file2   | 3 ---
+ dir/sub      | 2 ++
+ file0        | 3 +++
+ file2 (gone) | 3 ---
  3 files changed, 5 insertions(+), 3 deletions(-)
- delete mode 100644 file2
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..8422d40 100644
@@ -51,10 +50,9 @@ Date: Mon, 26 Jun 2006 00:02:00 +0000
 Subject: [PATCH 2/2] Third
 
 ---
- dir/sub | 2 ++
- file1   | 3 +++
+ dir/sub     | 2 ++
+ file1 (new) | 3 +++
  2 files changed, 5 insertions(+)
- create mode 100644 file1
 
 diff --git a/dir/sub b/dir/sub
 index 8422d40..cead32e 100644
diff --git a/t/t4013/diff.format-patch_--stdout_initial..side b/t/t4013/diff.format-patch_--stdout_initial..side
index a7d52fbeea..59db45454b 100644
--- a/t/t4013/diff.format-patch_--stdout_initial..side
+++ b/t/t4013/diff.format-patch_--stdout_initial..side
@@ -5,11 +5,10 @@ Date: Mon, 26 Jun 2006 00:03:00 +0000
 Subject: [PATCH] Side
 
 ---
- dir/sub | 2 ++
- file0   | 3 +++
- file3   | 4 ++++
+ dir/sub     | 2 ++
+ file0       | 3 +++
+ file3 (new) | 4 ++++
  3 files changed, 9 insertions(+)
- create mode 100644 file3
 
 diff --git a/dir/sub b/dir/sub
 index 35d242b..7289e35 100644
diff --git a/t/t4052-stat-output.sh b/t/t4052-stat-output.sh
index 6e2cf933f7..acea4c0b76 100755
--- a/t/t4052-stat-output.sh
+++ b/t/t4052-stat-output.sh
@@ -267,10 +267,10 @@ log -1 --stat
 EOF
 
 cat >expect72 <<'EOF'
- ...aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa | 1000 +++++++++++++++++
+ ...aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa (new) | 1000 +++++++++++++++++
 EOF
 cat >expect72-graph <<'EOF'
-|  ...aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa | 1000 +++++++++++++++++
+|  ...aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa (new) | 1000 +++++++++++++++++
 EOF
 cat >expect200 <<'EOF'
  aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa | 1000 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- 
2.16.2.903.gd04caf5039


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] format-patch: use --compact-summary instead of --summary
  2018-03-16 20:06 [PATCH] format-patch: use --compact-summary instead of --summary Nguyễn Thái Ngọc Duy
@ 2018-03-16 21:41 ` Junio C Hamano
  2018-03-17  8:08   ` Duy Nguyen
  0 siblings, 1 reply; 3+ messages in thread
From: Junio C Hamano @ 2018-03-16 21:41 UTC (permalink / raw)
  To: Nguyễn Thái Ngọc Duy; +Cc: git

Nguyễn Thái Ngọc Duy  <pclouds@gmail.com> writes:

> For reviewers, a couple fewer lines from diffstat (either cover letter
> or patches) is a good thing because there's less to read.

I can certainly accept that there may be some reviewers who share
that view, but me personally, I would rather have them outside the
main diffstat section, so addition and removal of files that are
rarer events do stand out.

I guess people would not mind an option to use it, but they can
already say "git format-patch --compact-summary $upstream..", so...



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] format-patch: use --compact-summary instead of --summary
  2018-03-16 21:41 ` Junio C Hamano
@ 2018-03-17  8:08   ` Duy Nguyen
  0 siblings, 0 replies; 3+ messages in thread
From: Duy Nguyen @ 2018-03-17  8:08 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: Git Mailing List

On Fri, Mar 16, 2018 at 10:41 PM, Junio C Hamano <gitster@pobox.com> wrote:
> Nguyễn Thái Ngọc Duy  <pclouds@gmail.com> writes:
>
>> For reviewers, a couple fewer lines from diffstat (either cover letter
>> or patches) is a good thing because there's less to read.
>
> I can certainly accept that there may be some reviewers who share
> that view, but me personally, I would rather have them outside the
> main diffstat section, so addition and removal of files that are
> rarer events do stand out.
>
> I guess people would not mind an option to use it, but they can
> already say "git format-patch --compact-summary $upstream..", so...

Good point. I can't negate --summary though. But that calls for another patch.
-- 
Duy

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-03-17  8:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-16 20:06 [PATCH] format-patch: use --compact-summary instead of --summary Nguyễn Thái Ngọc Duy
2018-03-16 21:41 ` Junio C Hamano
2018-03-17  8:08   ` Duy Nguyen

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).