Merge branch 'jc/better-conflict-resolution'
* jc/better-conflict-resolution: Fix AsciiDoc errors in merge documentation git-merge documentation: describe how conflict is presented checkout --conflict=<style>: recreate merge in a non-default style checkout -m: recreate merge when checking out of unmerged index git-merge-recursive: learn to honor merge.conflictstyle merge.conflictstyle: choose between "merge" and "diff3 -m" styles rerere: understand "diff3 -m" style conflicts with the original rerere.c: use symbolic constants to keep track of parsing states xmerge.c: "diff3 -m" style clips merge reduction level to EAGER or less xmerge.c: minimum readability fixups xdiff-merge: optionally show conflicts in "diff3 -m" style xdl_fill_merge_buffer(): separate out a too deeply nested function checkout --ours/--theirs: allow checking out one side of a conflicting merge checkout -f: allow ignoring unmerged paths when checking out of the index Conflicts: Documentation/git-checkout.txt builtin-checkout.c builtin-merge-recursive.c t/t7201-co.sh
This commit is contained in:
@ -249,3 +249,23 @@ void xdiff_set_find_func(xdemitconf_t *xecfg, const char *value)
|
||||
value = ep + 1;
|
||||
}
|
||||
}
|
||||
|
||||
int git_xmerge_style = -1;
|
||||
|
||||
int git_xmerge_config(const char *var, const char *value, void *cb)
|
||||
{
|
||||
if (!strcasecmp(var, "merge.conflictstyle")) {
|
||||
if (!value)
|
||||
die("'%s' is not a boolean", var);
|
||||
if (!strcmp(value, "diff3"))
|
||||
git_xmerge_style = XDL_MERGE_DIFF3;
|
||||
else if (!strcmp(value, "merge"))
|
||||
git_xmerge_style = 0;
|
||||
else
|
||||
die("unknown style '%s' given for '%s'",
|
||||
value, var);
|
||||
return 0;
|
||||
}
|
||||
return git_default_config(var, value, cb);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user