]> git.ipfire.org Git - thirdparty/git.git/commitdiff
merge-ort: remove command-line-centric submodule message from merge-ort
authorElijah Newren <newren@gmail.com>
Sat, 18 Jun 2022 00:20:51 +0000 (00:20 +0000)
committerJunio C Hamano <gitster@pobox.com>
Wed, 22 Jun 2022 23:10:06 +0000 (16:10 -0700)
There was one case in merge-ort that would call path_msg() multiple
times for the same logical conflict, and it was in order to give advice
about how to resolve a conflict.  This advice does not make as much
sense with remerge-diff, or with merge-tree being invoked by a GitHub
GUI for resolution of messages, and is making it hard to provide
which-logical-conflict-affects-which-paths information in a machine
parseable way to a higher level caller of merge-tree.  Let's simply
remove this informational message.

Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
merge-ort.c
t/t6437-submodule-merge.sh

index bc1fcad8b487ad747277a976c93c1a76ef2dc730..3432efcacdc3fa06afdddc36352040dce228ecbb 100644 (file)
@@ -1694,15 +1694,8 @@ static int merge_submodule(struct merge_options *opt,
                              (struct commit *)merges.objects[0].item);
                path_msg(opt, path, 0,
                         _("Failed to merge submodule %s, but a possible merge "
-                          "resolution exists:\n%s\n"),
+                          "resolution exists: %s"),
                         path, sb.buf);
-               path_msg(opt, path, 1,
-                        _("If this is correct simply add it to the index "
-                          "for example\n"
-                          "by using:\n\n"
-                          "  git update-index --cacheinfo 160000 %s \"%s\"\n\n"
-                          "which will accept this suggestion.\n"),
-                        oid_to_hex(&merges.objects[0].item->oid), path);
                strbuf_release(&sb);
                break;
        default:
index 178413c22f0dc1dd03152ec1d84843e070d1d843..c253bf759ab12629ad4bba872af8f9bd51f78e1b 100755 (executable)
@@ -133,7 +133,7 @@ test_expect_success 'merging should conflict for non fast-forward' '
        (cd merge-search &&
         git checkout -b test-nonforward b &&
         (cd sub &&
-         git rev-parse sub-d > ../expect) &&
+         git rev-parse --short sub-d > ../expect) &&
          if test "$GIT_TEST_MERGE_ALGORITHM" = ort
          then
                test_must_fail git merge c >actual