From: Linus Torvalds <torvalds@linux-foundation.org>
To: Junio C Hamano <gitster@pobox.com>
Cc: Paul Mackerras <paulus@samba.org>, git@vger.kernel.org
Subject: Re: filenames with " b" in them create confusing git diff-tree output
Date: Wed, 20 Jun 2007 13:23:12 -0700 (PDT) [thread overview]
Message-ID: <alpine.LFD.0.98.0706201315310.3593@woody.linux-foundation.org> (raw)
In-Reply-To: <7v4pl2v1lf.fsf@assigned-by-dhcp.pobox.com>
On Wed, 20 Jun 2007, Junio C Hamano wrote:
>
> Your example, "a/test b/foo" vs "b/test b/foo", can be and IS
> parsed unambiguously by git-apply (you can try "git apply
> --stat" your example). IOW, the code to correctly handle it
> already exists ;-)
Well, in all fairness, I *did* hate having to write the code to handle all
the name handling in git-apply.
Escaping whitespace (or at least giving the _option_ to do so) might well
be a good way to not have to be as smart as git-apply is.
git-apply didn't have that option, since git-apply has as one primary
motivation the need to be able to handle patches that come from non-git
sources, so git-apply goes to quite some extreme lengths to try to make
sense of an inherently rather ambiguous format (that the git diffs then
*made* unambiguous, but using pretty subtle rules in order to stay
compatible).
Some maybe we should have some generic method of asking for any filename
to be quoted in particular ways?
Linus
next prev parent reply other threads:[~2007-06-20 20:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-06-20 11:15 filenames with " b" in them create confusing git diff-tree output Paul Mackerras
2007-06-20 19:59 ` Junio C Hamano
2007-06-20 20:23 ` Linus Torvalds [this message]
2007-06-20 20:50 ` 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=alpine.LFD.0.98.0706201315310.3593@woody.linux-foundation.org \
--to=torvalds@linux-foundation.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=paulus@samba.org \
/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