From: Junio C Hamano <gitster@pobox.com>
To: Fernando Ramos <greenfoo@u92.eu>
Cc: Johannes Schindelin via GitGitGadget <gitgitgadget@gmail.com>,
git@vger.kernel.org,
Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re: [PATCH] mergetool(vimdiff): allow paths to contain spaces again
Date: Wed, 13 Jul 2022 15:33:53 -0700 [thread overview]
Message-ID: <xmqqa69cabhq.fsf@gitster.g> (raw)
In-Reply-To: <Ys9Ftu3z6zedCsoX@zacax395.localdomain> (Fernando Ramos's message of "Thu, 14 Jul 2022 00:22:46 +0200")
Fernando Ramos <greenfoo@u92.eu> writes:
> On 22/07/13 02:54PM, Junio C Hamano wrote:
>>
>> OK, because "1" fails to execute, the expected output Dscho had
>> (which is for the case without base) would become invalid when we
>> use "true".
>>
>> Perhaps we should use "false" instead? Or do we need to test both?
>>
> I think testing both is not really needed as the unit test is just making sure
> that filenames with spaces are processed correctly. Whatever comes before
> (which changes depending on the value of "base_present") doesn't really matter
> as long as there is something.
As the quoting glitch are distributed on both sides
if $base_present
then
eval "$merge_tool_path" \
-f "$FINAL_CMD" "$LOCAL" "$BASE" "$REMOTE" "$MERGED"
else
# If there is no BASE (example: a merge conflict in a new file
# with the same name created in both braches which didn't exist
# before), close all BASE windows using vim's "quit" command
FINAL_CMD=$(echo "$FINAL_CMD" | \
sed -e 's:2b:quit:g' -e 's:3b:2b:g' -e 's:4b:3b:g')
eval "$merge_tool_path" \
-f "$FINAL_CMD" "$LOCAL" "$REMOTE" "$MERGED"
fi
I suspect you can fix only one, and carefully choose which side to
test, and leave the other side broken ;-)
In any case, to minimize disruption to Dscho's patch, I replaced the
"1" with "false" (which will make his patch pass the new test
without other stuff) and tweak its merge into 'seen' to adjust for
the "leftabove" topic.
Thanks.
next prev parent reply other threads:[~2022-07-13 22:34 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-13 15:42 [PATCH] mergetool(vimdiff): allow paths to contain spaces again Johannes Schindelin via GitGitGadget
2022-07-13 16:22 ` Junio C Hamano
2022-07-13 20:52 ` Fernando Ramos
2022-07-13 20:54 ` Junio C Hamano
2022-07-13 21:08 ` Junio C Hamano
2022-07-13 21:33 ` Fernando Ramos
2022-07-13 21:54 ` Junio C Hamano
2022-07-13 22:06 ` Junio C Hamano
2022-07-13 22:28 ` Fernando Ramos
2022-07-13 22:22 ` Fernando Ramos
2022-07-13 22:33 ` Junio C Hamano [this message]
2022-07-14 14:31 ` [PATCH v2] " Johannes Schindelin via GitGitGadget
2022-07-14 16:27 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqa69cabhq.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=greenfoo@u92.eu \
--cc=johannes.schindelin@gmx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).