Re: [PATCH] git-svn: Add a svn-remote.<name>.pushurl config key

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Apr 08, 2011 at 02:22:11PM -0700, Junio C Hamano wrote:

> Jeff King <peff@xxxxxxxx> writes:
> 
> > I think format-patch is totally lacking in this type of quoting. If I
> > do:
> >
> >   $ git init
> >   $ git config user.name '<bogus> with "quotes"'
> >   $ echo contents >foo && git add . && git commit -m foo
> >   $ git format-patch --stdout --root
> >   ...
> >   From: bogus with "quotes <peff@xxxxxxxx>
> >
> > So some of my magic characters are just stripped, and some of them get
> > included, making the output bogus (the stripping of <> actually happens
> > within git, so the commit itself is missing them).
> 
> The output from format-patch is meant to be slurped into MUA, so I would
> say that they should show what a human user would type the name to
> Thunderbird or message.el or whatever, and it is MUA's respoinsibility to
> make it RFC comformant.  And that is why I mentioned that send-email
> may want to learn a new trick or two.

I disagree. Format-patch claims to make an mbox, so it should make one
that is valid (actually, the documentation is very wishy-washy about
whether it is an mbox; we say "formatted to resemble UNIX mailbox
format" at one point, and "print all commits...in mbox format" later).

But that is a philosophical distinction. What matters in practice is
what MUAs expect to get, and how they deal with it. I expect most MUAs
handle bare "." just fine, because it's fairly unambiguous. But try:

  git init repo && cd repo
  git config user.name 'Jeff "Peff" King' &&
  echo content >>file &&
  git add file &&
  git commit -m one

  git format-patch -1 --stdout >mbox

now open the result in your MUA. Mutt strips the quotes and I become
"Jeff Peff King".

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]