Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Sunshine <sunshine@sunshineco.com>2018-07-22 12:57:12 +0300
committerJunio C Hamano <gitster@pobox.com>2018-08-15 00:27:04 +0300
commit73a834e9e27906a76940f1ced5c132bce205d3f8 (patch)
treee54e674b2e78723a111cf40733dd453fba5ed3f3 /range-diff.h
parent25668659bfd74a71de6dd27eac437a17ad72a315 (diff)
range-diff: relieve callers of low-level configuration burden
There are a number of very low-level configuration details which need to be managed precisely to generate a proper range-diff. In particular, 'diff_options' output format, header suppression, indentation, and dual-color mode must all be set appropriately to ensure proper behavior. Handle these details locally in the libified range-diff back-end rather than forcing each caller to have specialized knowledge of these implementation details, and to avoid duplication as new callers are added. While at it, localize these tweaks to be active only while generating the range-diff, so they don't clobber the caller-provided 'diff_options', which might be used beyond range-diff generation. Signed-off-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'range-diff.h')
-rw-r--r--range-diff.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/range-diff.h b/range-diff.h
index f26de5d0b0..190593f0c7 100644
--- a/range-diff.h
+++ b/range-diff.h
@@ -6,6 +6,7 @@
#define RANGE_DIFF_CREATION_FACTOR_DEFAULT 60
int show_range_diff(const char *range1, const char *range2,
- int creation_factor, struct diff_options *diffopt);
+ int creation_factor, int dual_color,
+ struct diff_options *diffopt);
#endif