{"thread":{"id":"19956","subject":"[PATCH] Remove filename from conflict markers","startedAt":"2009-06-28T15:45:59Z","lastAt":"2009-07-01T20:57:54Z","messageCount":8,"participants":["Martin Renold","Junio C Hamano","Nanako Shiraishi"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"117131","messageId":"20090628154559.GA29049@old.homeip.net","threadId":"19956","inReplyTo":null,"subject":"[PATCH] Remove filename from conflict markers","fromName":"Martin Renold","fromEmail":"martinxyz@gmx.ch","sentAt":"2009-06-28T15:45:59Z","receivedAt":"2009-06-28T15:45:59Z","isPatch":true,"sender":{"key":"martinxyz@gmx.ch","avatar":"https://gravatar.com/avatar/d7e48822e95974d46609fcbea9399ebe278d4be27496000352633767a19ac3c1?d=mp&s=160"},"body":"Put filenames into the conflict markers only when they are different.\nOtherwise they are redundant information clutter.\n\nSigned-off-by: Martin Renold <martinxyz@gmx.ch>\n---\n merge-recursive.c             |    9 +++++++--\n t/t3404-rebase-interactive.sh |    4 ++--\n 2 files changed, 9 insertions(+), 4 deletions(-)\n\ndiff --git a/merge-recursive.c b/merge-recursive.c\nindex c703445..53cad96 100644\n--- a/merge-recursive.c\n+++ b/merge-recursive.c\n@@ -622,8 +622,13 @@ static int merge_3way(struct merge_options *o,\n \tchar *name1, *name2;\n \tint merge_status;\n \n-\tname1 = xstrdup(mkpath(\"%s:%s\", branch1, a->path));\n-\tname2 = xstrdup(mkpath(\"%s:%s\", branch2, b->path));\n+\tif (strcmp(a->path, b->path)) {\n+\t\tname1 = xstrdup(mkpath(\"%s:%s\", branch1, a->path));\n+\t\tname2 = xstrdup(mkpath(\"%s:%s\", branch2, b->path));\n+\t} else {\n+\t\tname1 = xstrdup(mkpath(\"%s\", branch1));\n+\t\tname2 = xstrdup(mkpath(\"%s\", branch2));\n+\t}\n \n \tfill_mm(one->sha1, &orig);\n \tfill_mm(a->sha1, &src1);\ndiff --git a/t/t3404-rebase-interactive.sh b/t/t3404-rebase-interactive.sh\nindex c32ff66..a973628 100755\n--- a/t/t3404-rebase-interactive.sh\n+++ b/t/t3404-rebase-interactive.sh\n@@ -119,11 +119,11 @@ index e69de29..00750ed 100644\n EOF\n \n cat > expect2 << EOF\n-<<<<<<< HEAD:file1\n+<<<<<<< HEAD\n 2\n =======\n 3\n->>>>>>> b7ca976... G:file1\n+>>>>>>> b7ca976... G\n EOF\n \n test_expect_success 'stop on conflicting pick' '\n-- \n1.6.3.1\n"},{"id":"117267","messageId":"7v63ed5pvi.fsf@alter.siamese.dyndns.org","threadId":"19956","inReplyTo":"20090628154559.GA29049@old.homeip.net","subject":"Re: [PATCH] Remove filename from conflict markers","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-06-30T22:16:33Z","receivedAt":"2009-06-30T22:16:33Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Martin Renold <martinxyz@gmx.ch> writes:\n\n> Put filenames into the conflict markers only when they are different.\n> Otherwise they are redundant information clutter.\n>\n> Signed-off-by: Martin Renold <martinxyz@gmx.ch>\n> ---\n>  merge-recursive.c             |    9 +++++++--\n>  t/t3404-rebase-interactive.sh |    4 ++--\n\nThe change seems to break more tests than just 3404.\n\nI also wondered briefly if it will break people's existing scripts;\nI suspect it will not likely to be a huge problem.\n\n>  2 files changed, 9 insertions(+), 4 deletions(-)\n>\n> diff --git a/merge-recursive.c b/merge-recursive.c\n> index c703445..53cad96 100644\n> --- a/merge-recursive.c\n> +++ b/merge-recursive.c\n> @@ -622,8 +622,13 @@ static int merge_3way(struct merge_options *o,\n>  \tchar *name1, *name2;\n>  \tint merge_status;\n>  \n> -\tname1 = xstrdup(mkpath(\"%s:%s\", branch1, a->path));\n> -\tname2 = xstrdup(mkpath(\"%s:%s\", branch2, b->path));\n> +\tif (strcmp(a->path, b->path)) {\n> +\t\tname1 = xstrdup(mkpath(\"%s:%s\", branch1, a->path));\n> +\t\tname2 = xstrdup(mkpath(\"%s:%s\", branch2, b->path));\n> +\t} else {\n> +\t\tname1 = xstrdup(mkpath(\"%s\", branch1));\n> +\t\tname2 = xstrdup(mkpath(\"%s\", branch2));\n> +\t}\n>  \n>  \tfill_mm(one->sha1, &orig);\n>  \tfill_mm(a->sha1, &src1);\n> diff --git a/t/t3404-rebase-interactive.sh b/t/t3404-rebase-interactive.sh\n> index c32ff66..a973628 100755\n> --- a/t/t3404-rebase-interactive.sh\n> +++ b/t/t3404-rebase-interactive.sh\n> @@ -119,11 +119,11 @@ index e69de29..00750ed 100644\n>  EOF\n>  \n>  cat > expect2 << EOF\n> -<<<<<<< HEAD:file1\n> +<<<<<<< HEAD\n>  2\n>  =======\n>  3\n> ->>>>>>> b7ca976... G:file1\n> +>>>>>>> b7ca976... G\n>  EOF\n>  \n>  test_expect_success 'stop on conflicting pick' '\n> -- \n> 1.6.3.1\n"},{"id":"117283","messageId":"20090701123310.6117@nanako3.lavabit.com","threadId":"19956","inReplyTo":"7v63ed5pvi.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] Remove filename from conflict markers","fromName":"Nanako Shiraishi","fromEmail":"nanako3@lavabit.com","sentAt":"2009-07-01T03:33:10Z","receivedAt":"2009-07-01T03:33:10Z","isPatch":true,"sender":{"key":"nanako3@lavabit.com","avatar":"https://gravatar.com/avatar/3777b9e201c5883a62b1a6fdf7c53f2d712d1d80989146063ea861e33aad72a8?d=mp&s=160"},"body":"Quoting Junio C Hamano <gitster@pobox.com>:\n\n> Martin Renold <martinxyz@gmx.ch> writes:\n>\n>> Put filenames into the conflict markers only when they are different.\n>> Otherwise they are redundant information clutter.\n>>\n>> Signed-off-by: Martin Renold <martinxyz@gmx.ch>\n>> ---\n>>  merge-recursive.c             |    9 +++++++--\n>>  t/t3404-rebase-interactive.sh |    4 ++--\n>\n> The change seems to break more tests than just 3404.\n>\n> I also wondered briefly if it will break people's existing scripts;\n> I suspect it will not likely to be a huge problem.\n\nI needed to apply the attached patch to make the tests pass. The last part clearly shows that this change introduces a usability regression. In the error message the user can no longer see which file was problematic.\n\nI request Martin's patch to be dropped.\n\n t/t6024-recursive-merge.sh |    8 ++++----\n 1 files changed, 4 insertions(+), 4 deletions(-)\n\ndiff --git a/t/t6024-recursive-merge.sh b/t/t6024-recursive-merge.sh\nindex 129fa30..a9c4a02 100755\n--- a/t/t6024-recursive-merge.sh\n+++ b/t/t6024-recursive-merge.sh\n@@ -65,18 +65,18 @@ test_expect_success \"combined merge conflicts\" \"\n \"\n \n cat > expect << EOF\n-<<<<<<< HEAD:a1\n+<<<<<<< HEAD\n F\n =======\n G\n->>>>>>> G:a1\n+>>>>>>> G\n EOF\n \n test_expect_success \"result contains a conflict\" \"test_cmp expect a1\"\n \n git ls-files --stage > out\n cat > expect << EOF\n-100644 da056ce14a2241509897fa68bb2b3b6e6194ef9e 1\ta1\n+100644 439cc46de773d8a83c77799b7cc9191c128bfcff 1\ta1\n 100644 cf84443e49e1b366fac938711ddf4be2d4d1d9e9 2\ta1\n 100644 fd7923529855d0b274795ae3349c5e0438333979 3\ta1\n EOF\n@@ -93,7 +93,7 @@ test_expect_success 'refuse to merge binary files' '\n \tgit add binary-file &&\n \tgit commit -m binary2 &&\n \ttest_must_fail git merge F > merge.out 2> merge.err &&\n-\tgrep \"Cannot merge binary files: HEAD:binary-file vs. F:binary-file\" \\\n+\tgrep \"Cannot merge binary files: HEAD vs. F\" \\\n \t\tmerge.err\n '\n\n-- \nNanako Shiraishi\nhttp://ivory.ap.teacup.com/nanako3/\n"},{"id":"117292","messageId":"20090701075634.GA18326@old.homeip.net","threadId":"19956","inReplyTo":"20090701123310.6117@nanako3.lavabit.com","subject":"Re: [PATCH] Remove filename from conflict markers","fromName":"Martin Renold","fromEmail":"martinxyz@gmx.ch","sentAt":"2009-07-01T07:56:34Z","receivedAt":"2009-07-01T07:56:34Z","isPatch":true,"sender":{"key":"martinxyz@gmx.ch","avatar":"https://gravatar.com/avatar/d7e48822e95974d46609fcbea9399ebe278d4be27496000352633767a19ac3c1?d=mp&s=160"},"body":"On Wed, Jul 01, 2009 at 12:33:10PM +0900, Nanako Shiraishi wrote:\n> The last part clearly shows that this change introduces a usability\n> regression.  In the error message the user can no longer see which file\n> was problematic.\n\nNot true. The filename is still printed two times in the case of \"git\nmerge\", and four times with \"git rebase\".  The user still sees the required\ninformation, there are just fewer repetitions.\n\nThe previous warning was a bit nicer for copy-paste, allthough I don't see\nwhy it should print things so differently compared to textual conflicts.\n\n> -     grep \"Cannot merge binary files: HEAD:binary-file vs. F:binary-file\" \\\n> +     grep \"Cannot merge binary files: HEAD vs. F\" \\\n>               merge.err\n\nWe could als fix that test by expecting the filename on stdout:\n\ndiff --git a/t/t6024-recursive-merge.sh b/t/t6024-recursive-merge.sh\nindex 129fa30..0c6b1ea 100755\n--- a/t/t6024-recursive-merge.sh\n+++ b/t/t6024-recursive-merge.sh\n@@ -65,18 +65,18 @@ test_expect_success \"combined merge conflicts\" \"\n \"\n \n cat > expect << EOF\n-<<<<<<< HEAD:a1\n+<<<<<<< HEAD\n F\n =======\n G\n->>>>>>> G:a1\n+>>>>>>> G\n EOF\n \n test_expect_success \"result contains a conflict\" \"test_cmp expect a1\"\n \n git ls-files --stage > out\n cat > expect << EOF\n-100644 da056ce14a2241509897fa68bb2b3b6e6194ef9e 1      a1\n+100644 439cc46de773d8a83c77799b7cc9191c128bfcff 1      a1\n 100644 cf84443e49e1b366fac938711ddf4be2d4d1d9e9 2      a1\n 100644 fd7923529855d0b274795ae3349c5e0438333979 3      a1\n EOF\n@@ -93,8 +93,8 @@ test_expect_success 'refuse to merge binary files' '\n        git add binary-file &&\n        git commit -m binary2 &&\n        test_must_fail git merge F > merge.out 2> merge.err &&\n-       grep \"Cannot merge binary files: HEAD:binary-file vs. F:binary-file\" \\\n-               merge.err\n+       grep \"Cannot merge binary files: HEAD vs. F\" merge.err\n+       grep \"Merge conflict in binary-file\" merge.out\n '\n \n test_expect_success 'mark rename/delete as unmerged' '\n\nbye,\nMartin\n"},{"id":"117295","messageId":"7vljn8ls0c.fsf@alter.siamese.dyndns.org","threadId":"19956","inReplyTo":"20090701075634.GA18326@old.homeip.net","subject":"Re: [PATCH] Remove filename from conflict markers","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-07-01T08:36:03Z","receivedAt":"2009-07-01T08:36:03Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Martin Renold <martinxyz@gmx.ch> writes:\n\n>  test_expect_success \"result contains a conflict\" \"test_cmp expect a1\"\n>  \n>  git ls-files --stage > out\n>  cat > expect << EOF\n> -100644 da056ce14a2241509897fa68bb2b3b6e6194ef9e 1      a1\n> +100644 439cc46de773d8a83c77799b7cc9191c128bfcff 1      a1\n>  100644 cf84443e49e1b366fac938711ddf4be2d4d1d9e9 2      a1\n>  100644 fd7923529855d0b274795ae3349c5e0438333979 3      a1\n>  EOF\n\nI think Nana's patch also had this, but what is this hunk about?  IOW, why\ndoes stage #1 (common ancestor's version) even change?\n\nIs this a virtual ancestor in a criss-cross recursive merge?\n\n> @@ -93,8 +93,8 @@ test_expect_success 'refuse to merge binary files' '\n>         git add binary-file &&\n>         git commit -m binary2 &&\n>         test_must_fail git merge F > merge.out 2> merge.err &&\n> -       grep \"Cannot merge binary files: HEAD:binary-file vs. F:binary-file\" \\\n> -               merge.err\n> +       grep \"Cannot merge binary files: HEAD vs. F\" merge.err\n> +       grep \"Merge conflict in binary-file\" merge.out\n>  '\n\nAt the end of the first \"grep\" && is missing.  But more importantly, would\nthis new output format really as informative as you claim, even when the\nfile that cannot be automerged due to its binaryness is not named\n\"binary-file\" but simply say \"X\"?  The merge.err output shows that there\nwere some file that failed to merge due to being binary, and merge.out\noutput owuld show that \"X\" had conflict.  Would it be just as easy for the\nend user to connect these two as it used to be?\n\nI for now am assuming no mechanical end user is parsing this output to\nfigure out what to do, but that assumption might even be wrong.\n"},{"id":"117302","messageId":"20090701161651.GA29393@old.homeip.net","threadId":"19956","inReplyTo":"7vljn8ls0c.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH] Remove filename from conflict markers","fromName":"Martin Renold","fromEmail":"martinxyz@gmx.ch","sentAt":"2009-07-01T16:16:51Z","receivedAt":"2009-07-01T16:16:51Z","isPatch":true,"sender":{"key":"martinxyz@gmx.ch","avatar":"https://gravatar.com/avatar/d7e48822e95974d46609fcbea9399ebe278d4be27496000352633767a19ac3c1?d=mp&s=160"},"body":"On Wed, Jul 01, 2009 at 01:36:03AM -0700, Junio C Hamano wrote:\n> Martin Renold <martinxyz@gmx.ch> writes:\n> >  git ls-files --stage > out\n> >  cat > expect << EOF\n> > -100644 da056ce14a2241509897fa68bb2b3b6e6194ef9e 1      a1\n> > +100644 439cc46de773d8a83c77799b7cc9191c128bfcff 1      a1\n> >  100644 cf84443e49e1b366fac938711ddf4be2d4d1d9e9 2      a1\n> >  100644 fd7923529855d0b274795ae3349c5e0438333979 3      a1\n> >  EOF\n> \n> I think Nana's patch also had this, but what is this hunk about?  IOW, why\n> does stage #1 (common ancestor's version) even change?\n> \n> Is this a virtual ancestor in a criss-cross recursive merge?\n\nThe file contains conflict markers, which is why it changes. I don't\nunderstand why it has them. The merge looks pretty complex.\n\n> But more importantly, would this new output format really as informative\n> as you claim, even when the file that cannot be automerged due to its\n> binaryness is not named \"binary-file\" but simply say \"X\"?  The merge.err\n> output shows that there were some file that failed to merge due to being\n> binary, and merge.out output owuld show that \"X\" had conflict.  Would it\n> be just as easy for the end user to connect these two as it used to be?\n\nYou are right. With both binary and textual conflicts at the same time, the\nuser can not connect the two events, except by already knowing which files\nare binary.\n\nI think ideally the different pieces of information (the filename, the fact\nthat it has a merge conflict, and that it is binary) should be printed only\nonce and together.  But this goes beyond what I want to do right now.\n\n>From an implementation point of view, the variables name1 and name2 seem to\nbe arbitrary, possibly user-defined conflict markers.  I think it is wrong\nto print them in ll_xdl_merge() as if they were filenames.  I will try to\nmake a new patch that also addresses this issue.\n\n> I for now am assuming no mechanical end user is parsing this output to\n> figure out what to do, but that assumption might even be wrong.\n\nIn the rebase scenario, the mechanical end user has like 5 different places\nwhere he could pick the filename from.  If I was writing a script I would\nnot expect such an output to remain stable.\n\nbye,\nMartin\n"},{"id":"117318","messageId":"20090701201804.GA16876@old.homeip.net","threadId":"19956","inReplyTo":"20090701161651.GA29393@old.homeip.net","subject":"[PATCH/v2] Remove filename from conflict markers","fromName":"Martin Renold","fromEmail":"martinxyz@gmx.ch","sentAt":"2009-07-01T20:18:04Z","receivedAt":"2009-07-01T20:18:04Z","isPatch":true,"sender":{"key":"martinxyz@gmx.ch","avatar":"https://gravatar.com/avatar/d7e48822e95974d46609fcbea9399ebe278d4be27496000352633767a19ac3c1?d=mp&s=160"},"body":"Put filenames into the conflict markers only when they are different.\nOtherwise they are redundant information clutter.\n\nPrint the filename explicitely when warning about a binary conflict.\n\nSigned-off-by: Martin Renold <martinxyz@gmx.ch>\n---\n\nThanks for your feedback. Here is the second attempt. It turned out that the\nrequired function arguments were already there, just unused.\n\n ll-merge.c                    |    8 ++++----\n merge-recursive.c             |    9 +++++++--\n t/t3404-rebase-interactive.sh |    4 ++--\n t/t6024-recursive-merge.sh    |    9 ++++-----\n 4 files changed, 17 insertions(+), 13 deletions(-)\n\ndiff --git a/ll-merge.c b/ll-merge.c\nindex 9168958..a2c13c4 100644\n--- a/ll-merge.c\n+++ b/ll-merge.c\n@@ -55,7 +55,7 @@ static int ll_binary_merge(const struct ll_merge_driver *drv_unused,\n \n static int ll_xdl_merge(const struct ll_merge_driver *drv_unused,\n \t\t\tmmbuffer_t *result,\n-\t\t\tconst char *path_unused,\n+\t\t\tconst char *path,\n \t\t\tmmfile_t *orig,\n \t\t\tmmfile_t *src1, const char *name1,\n \t\t\tmmfile_t *src2, const char *name2,\n@@ -67,10 +67,10 @@ static int ll_xdl_merge(const struct ll_merge_driver *drv_unused,\n \tif (buffer_is_binary(orig->ptr, orig->size) ||\n \t    buffer_is_binary(src1->ptr, src1->size) ||\n \t    buffer_is_binary(src2->ptr, src2->size)) {\n-\t\twarning(\"Cannot merge binary files: %s vs. %s\\n\",\n-\t\t\tname1, name2);\n+\t\twarning(\"Cannot merge binary files: %s (%s vs. %s)\\n\",\n+\t\t\tpath, name1, name2);\n \t\treturn ll_binary_merge(drv_unused, result,\n-\t\t\t\t       path_unused,\n+\t\t\t\t       path,\n \t\t\t\t       orig, src1, name1,\n \t\t\t\t       src2, name2,\n \t\t\t\t       virtual_ancestor);\ndiff --git a/merge-recursive.c b/merge-recursive.c\nindex c703445..53cad96 100644\n--- a/merge-recursive.c\n+++ b/merge-recursive.c\n@@ -622,8 +622,13 @@ static int merge_3way(struct merge_options *o,\n \tchar *name1, *name2;\n \tint merge_status;\n \n-\tname1 = xstrdup(mkpath(\"%s:%s\", branch1, a->path));\n-\tname2 = xstrdup(mkpath(\"%s:%s\", branch2, b->path));\n+\tif (strcmp(a->path, b->path)) {\n+\t\tname1 = xstrdup(mkpath(\"%s:%s\", branch1, a->path));\n+\t\tname2 = xstrdup(mkpath(\"%s:%s\", branch2, b->path));\n+\t} else {\n+\t\tname1 = xstrdup(mkpath(\"%s\", branch1));\n+\t\tname2 = xstrdup(mkpath(\"%s\", branch2));\n+\t}\n \n \tfill_mm(one->sha1, &orig);\n \tfill_mm(a->sha1, &src1);\ndiff --git a/t/t3404-rebase-interactive.sh b/t/t3404-rebase-interactive.sh\nindex c32ff66..a973628 100755\n--- a/t/t3404-rebase-interactive.sh\n+++ b/t/t3404-rebase-interactive.sh\n@@ -119,11 +119,11 @@ index e69de29..00750ed 100644\n EOF\n \n cat > expect2 << EOF\n-<<<<<<< HEAD:file1\n+<<<<<<< HEAD\n 2\n =======\n 3\n->>>>>>> b7ca976... G:file1\n+>>>>>>> b7ca976... G\n EOF\n \n test_expect_success 'stop on conflicting pick' '\ndiff --git a/t/t6024-recursive-merge.sh b/t/t6024-recursive-merge.sh\nindex 129fa30..b3fbf65 100755\n--- a/t/t6024-recursive-merge.sh\n+++ b/t/t6024-recursive-merge.sh\n@@ -65,18 +65,18 @@ test_expect_success \"combined merge conflicts\" \"\n \"\n \n cat > expect << EOF\n-<<<<<<< HEAD:a1\n+<<<<<<< HEAD\n F\n =======\n G\n->>>>>>> G:a1\n+>>>>>>> G\n EOF\n \n test_expect_success \"result contains a conflict\" \"test_cmp expect a1\"\n \n git ls-files --stage > out\n cat > expect << EOF\n-100644 da056ce14a2241509897fa68bb2b3b6e6194ef9e 1\ta1\n+100644 439cc46de773d8a83c77799b7cc9191c128bfcff 1\ta1\n 100644 cf84443e49e1b366fac938711ddf4be2d4d1d9e9 2\ta1\n 100644 fd7923529855d0b274795ae3349c5e0438333979 3\ta1\n EOF\n@@ -93,8 +93,7 @@ test_expect_success 'refuse to merge binary files' '\n \tgit add binary-file &&\n \tgit commit -m binary2 &&\n \ttest_must_fail git merge F > merge.out 2> merge.err &&\n-\tgrep \"Cannot merge binary files: HEAD:binary-file vs. F:binary-file\" \\\n-\t\tmerge.err\n+\tgrep \"Cannot merge binary files: binary-file (HEAD vs. F)\" merge.err\n '\n \n test_expect_success 'mark rename/delete as unmerged' '\n-- \n1.6.3.1\n"},{"id":"117319","messageId":"7vljn8f7e5.fsf@alter.siamese.dyndns.org","threadId":"19956","inReplyTo":"20090701201804.GA16876@old.homeip.net","subject":"Re: [PATCH/v2] Remove filename from conflict markers","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-07-01T20:57:54Z","receivedAt":"2009-07-01T20:57:54Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Martin Renold <martinxyz@gmx.ch> writes:\n\n> Put filenames into the conflict markers only when they are different.\n> Otherwise they are redundant information clutter.\n>\n> Print the filename explicitely when warning about a binary conflict.\n\nI think we are getting closer.\n\n> -\tgrep \"Cannot merge binary files: HEAD:binary-file vs. F:binary-file\" \\\n> -\t\tmerge.err\n> +\tgrep \"Cannot merge binary files: binary-file (HEAD vs. F)\" merge.err\n\nIn the original code, if you are not in \"merge renamed\" situation, you\nwould see something like this.\n\n    \"Cannot merge binary files: HEAD:porn.jpg vs F:porn.jpg\"\n\nAnd the patch changes it to\n\n    \"Cannot merge binary files: porn.jpg (HEAD vs F)\"\n\nwhich is an improvement.  I have to wonder, if it even necessary to say\nHEAD vs F when no rename is involved, though.  Probably it is, as this is\nabout binary files, and the user may need to extract the contents with\nsomething like \"git cat-file blob HEAD:porn.jpg >tmp1.jpg\".\n\nWhen you are indeed in \"merge renamed\" situation, it gets a bit more\ninteresting.  The original said\n\n    \"Cannot merge binary files: HEAD:porn.jpg vs F:porn112.jpg\"\n\nwhich makes it clear that what is merged with what, but did not say where\nthe resulting merge will go.  The updated output would say something like\nthis\n\n    \"Cannot merge binary files: porn.jpg (HEAD:porn.jpg vs F:porn112.jpg)\"\n\nwhich adds information and is probably better.\n\nSo overall, I like what the change does, but I'd probably wait for a few\nmore days just in case there are objections from different corners,\nprimarily because I am somewhat concerned that this change might affect\nusers of mergetool (which I do not use myself) in some negative way.\n"}]}