diff options
| author | Junio C Hamano <gitster@pobox.com> | 2024-05-06 09:40:31 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2024-05-06 11:57:22 -0700 |
| commit | c22d41d641711879c57299244ae13b6c4a215fee (patch) | |
| tree | 9b44c53d41b31d75cf154b3137f5cd17bd6977af /builtin | |
| parent | Git 2.45 (diff) | |
| download | git-c22d41d641711879c57299244ae13b6c4a215fee.tar.gz git-c22d41d641711879c57299244ae13b6c4a215fee.zip | |
format-patch: run range-diff with larger creation-factor
We see too often that a range-diff added to format-patch output
shows too many "unmatched" patches. This is because the default
value for creation-factor is set to a relatively low value.
It may be justified for other uses (like you have a yet-to-be-sent
new iteration of your series, and compare it against the 'seen'
branch that has an older iteration, probably with the '--left-only'
option, to pick out only your patches while ignoring the others) of
"range-diff" command, but when the command is run as part of the
format-patch, the user _knows_ and expects that the patches in the
old and the new iterations roughly correspond to each other, so we
can and should use a much higher default.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
| -rw-r--r-- | builtin/log.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/log.c b/builtin/log.c index c0a8bb95e9..73608ffef9 100644 --- a/builtin/log.c +++ b/builtin/log.c @@ -2274,7 +2274,7 @@ int cmd_format_patch(int argc, const char **argv, const char *prefix) } if (creation_factor < 0) - creation_factor = RANGE_DIFF_CREATION_FACTOR_DEFAULT; + creation_factor = CREATION_FACTOR_FOR_THE_SAME_SERIES; else if (!rdiff_prev) die(_("the option '%s' requires '%s'"), "--creation-factor", "--range-diff"); |
