From ed34567c7bb1f3747255ca0301b84abad6d06712 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Thu, 14 Apr 2016 15:12:15 -0700 Subject: ll-merge: fix typo in comment When a944af1d (merge: teach -Xours/-Xtheirs to binary ll-merge driver, 2012-09-08) introduced FAVOR_OURS/FAVOR_THEIRS to the binary ll-merge driver, it changed what happens to the merge result for the outer merge, and updated the comment from: The tentative merge result is "ours" for the final round, or common ancestor for an internal merge. Still return "conflicted merge" status. to The tentative merge result is the or common ancestor for an internal merge. What happened is obvious. I noticed the lack of definitive article in front of "common" but failed to remove "or". Also I forgot to describe what I did for the final merge, probably because I was satisified by the description in the log message. Signed-off-by: Junio C Hamano --- ll-merge.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'll-merge.c') diff --git a/ll-merge.c b/ll-merge.c index 8ea03e536a..5c73274b13 100644 --- a/ll-merge.c +++ b/ll-merge.c @@ -46,7 +46,9 @@ static int ll_binary_merge(const struct ll_merge_driver *drv_unused, assert(opts); /* - * The tentative merge result is the or common ancestor for an internal merge. + * The tentative merge result is the common ancestor for an + * internal merge. For the final merge, it is "ours" by + * default but -Xours/-Xtheirs can tweak the choice. */ if (opts->virtual_ancestor) { stolen = orig; -- cgit v1.2.1 From d694a17986a28bbc19e2a6c32404ca24572e400f Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Thu, 14 Apr 2016 15:35:09 -0700 Subject: ll-merge: use a longer conflict marker for internal merge The primary use of conflict markers is to help the user who resolves the final (outer) merge by hand to show which part came from which branch by separating the blocks of lines apart. When the conflicted parts from a "virtual ancestor" merge created by merge-recursive remains in the common ancestor part in the final result, however, the conflict markers that are the same size as the final merge become harder to see. Increase the conflict marker size slightly for these inner merges so that the markers from the final merge and cruft from internal merge can be distinguished more easily. This would help reduce the common issue that prevents "rerere" from being used on a really complex conflict. Signed-off-by: Junio C Hamano --- ll-merge.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'll-merge.c') diff --git a/ll-merge.c b/ll-merge.c index 5c73274b13..e5ff7f6cb9 100644 --- a/ll-merge.c +++ b/ll-merge.c @@ -376,8 +376,12 @@ int ll_merge(mmbuffer_t *result_buf, } } driver = find_ll_merge_driver(ll_driver_name); - if (opts->virtual_ancestor && driver->recursive) - driver = find_ll_merge_driver(driver->recursive); + + if (opts->virtual_ancestor) { + if (driver->recursive) + driver = find_ll_merge_driver(driver->recursive); + marker_size += 2; + } return driver->fn(driver, result_buf, path, ancestor, ancestor_label, ours, our_label, theirs, their_label, opts, marker_size); -- cgit v1.2.1