summaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
authorLibravatar Johannes Schindelin <johannes.schindelin@gmx.de>2018-08-13 04:33:11 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-08-13 10:44:51 -0700
commit1cdde296a5d3b0fd17a3fcd7a0869550b064fdce (patch)
treef48a1106036a2bd2666f930685f961d48b2f6a83 /builtin
parentrange-diff: indent the diffs just like tbdiff (diff)
downloadtgif-1cdde296a5d3b0fd17a3fcd7a0869550b064fdce.tar.xz
range-diff: suppress the diff headers
When showing the diff between corresponding patches of the two branch versions, we have to make up a fake filename to run the diff machinery. That filename does not carry any meaningful information, hence tbdiff suppresses it. So we should, too. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
-rw-r--r--builtin/range-diff.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/builtin/range-diff.c b/builtin/range-diff.c
index f0598005ae..76659d0b3f 100644
--- a/builtin/range-diff.c
+++ b/builtin/range-diff.c
@@ -33,6 +33,7 @@ int cmd_range_diff(int argc, const char **argv, const char *prefix)
diff_setup(&diffopt);
diffopt.output_format = DIFF_FORMAT_PATCH;
+ diffopt.flags.suppress_diff_headers = 1;
diffopt.output_prefix = output_prefix_cb;
strbuf_addstr(&four_spaces, " ");
diffopt.output_prefix_data = &four_spaces;