X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=builtin%2Fmerge.c;h=10f091b51960cd6ae913b1c4d2ab9e6931862351;hb=5c28a8b054cb69a37638b0261fc370422c8fab58;hp=2dba3b9901cbdca9aee279339ecd3537e15e39da;hpb=9018af4f98b98738f3cd1268a16d143762ebb6f2;p=git.git diff --git a/builtin/merge.c b/builtin/merge.c index 2dba3b990..10f091b51 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -639,25 +639,9 @@ static int try_merge_strategy(const char *strategy, struct commit_list *common, o.renormalize = option_renormalize; - /* - * NEEDSWORK: merge with table in builtin/merge-recursive - */ - for (x = 0; x < xopts_nr; x++) { - if (!strcmp(xopts[x], "ours")) - o.recursive_variant = MERGE_RECURSIVE_OURS; - else if (!strcmp(xopts[x], "theirs")) - o.recursive_variant = MERGE_RECURSIVE_THEIRS; - else if (!strcmp(xopts[x], "subtree")) - o.subtree_shift = ""; - else if (!prefixcmp(xopts[x], "subtree=")) - o.subtree_shift = xopts[x]+8; - else if (!strcmp(xopts[x], "renormalize")) - o.renormalize = 1; - else if (!strcmp(xopts[x], "no-renormalize")) - o.renormalize = 0; - else + for (x = 0; x < xopts_nr; x++) + if (parse_merge_opt(&o, xopts[x])) die("Unknown option for merge-recursive: -X%s", xopts[x]); - } o.branch1 = head_arg; o.branch2 = remoteheads->item->util;