From: Junio C Hamano <gitster@pobox.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: git@vger.kernel.org, Paul Eggert <eggert@cs.ucla.edu>,
Andreas Gruenbacher <agruen@gnu.org>,
Gwyneth Morgan <gwymor@tilde.club>
Subject: Re: [PATCH 2/2] diff: --quote-path-with-sp
Date: Thu, 16 Sep 2021 13:59:15 -0700 [thread overview]
Message-ID: <xmqq35q4texo.fsf@gitster.g> (raw)
In-Reply-To: <87ee9ohnqd.fsf@evledraar.gmail.com> ("Ævar Arnfjörð Bjarmason"'s message of "Thu, 16 Sep 2021 11:06:42 +0200")
Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:
> On Wed, Sep 15 2021, Junio C Hamano wrote:
>
> [CC-ing Andreas Gruenbacher who's currently active in GNU patch
> development, and Paul Eggert at his current address, in case he's
> curious about this blast from the past.
>
> Both: The full context for this proposed change in Git is at
> https://lore.kernel.org/git/20210915223316.1653443-1-gitster@pobox.com/]
>
>> Long time ago, we had a discussion with GNU patch/diff maintainer
>> and agreed that pathnames with certain "difficult" bytes needs to be
>> quoted to ensure the resulting patch is machine parseable in an
>> unambiguous way [*1*]. Recently, we saw a report that found that
>> GNU patch is unhappy with our diff output for a path with SP in it
>> [*2*].
>
> It would also be good to mention 4f6fbcdcf96 ...
Ah, I didn't mean "this is the single message to understand the
issue". The reference was meant as "you need to read the discussion
that starts around here", which you apparently did ;-)
There is another message that is much more relevant that does not
appear in the thread (and I do not know its message ID), where Linus
came up with a way to parse the "diff --git a/... b/..." line, or
the first "--- a/..." and "+++ b/..." lines, and learn the pathnames
on the preimage side and on the postimage side unambiguously. I think
that discovery led to the current implementation.
next prev parent reply other threads:[~2021-09-16 20:59 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-15 22:33 [PATCH 0/2] (experimental) diff --quote-path-with-sp Junio C Hamano
2021-09-15 22:33 ` [PATCH 1/2] diff: simplify quote_two() Junio C Hamano
2021-09-15 22:33 ` [PATCH 2/2] diff: --quote-path-with-sp Junio C Hamano
2021-09-16 9:06 ` Ævar Arnfjörð Bjarmason
2021-09-16 20:59 ` Junio C Hamano [this message]
2021-09-16 3:33 ` [PATCH 0/2] (experimental) diff --quote-path-with-sp Gwyneth Morgan
2021-09-16 5:31 ` 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=xmqq35q4texo.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=agruen@gnu.org \
--cc=avarab@gmail.com \
--cc=eggert@cs.ucla.edu \
--cc=git@vger.kernel.org \
--cc=gwymor@tilde.club \
/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).