From: Jeff King <peff@peff.net>
To: kevin@lists.ikke.info
Cc: git@vger.kernel.org, Junio C Hamano <gitster@pobox.com>,
Kevin Daudt <me@ikke.info>
Subject: Re: [RFC 0/1] mailinfo: de-quote quoted-pair in header fields
Date: Tue, 13 Sep 2016 22:13:06 -0700 [thread overview]
Message-ID: <20160914051305.vphknpsikyxi3hg3@sigill.intra.peff.net> (raw)
In-Reply-To: <20160913234612.22806-2-me@ikke.info>
On Wed, Sep 14, 2016 at 01:46:12AM +0200, Kevin Daudt wrote:
> diff --git a/t/t5100/quoted-pair.expect b/t/t5100/quoted-pair.expect
> new file mode 100644
> index 0000000..9fe72e9
> --- /dev/null
> +++ b/t/t5100/quoted-pair.expect
> @@ -0,0 +1,5 @@
> +Author: "Author "The Author" Name"
> +Email: somebody@example.com
> +Subject: testing quoted-pair
> +Date: Sun, 25 May 2008 00:38:18 -0700
So obviously this is much better than including the backslashed quotes.
But I have to wonder why the first line is not:
Author: Author "The Author" Name
Who is responsible for stripping out the other quotes? I know that they
_do_ get stripped out even in the current code, but it is not clear to
me if that is intentional or an accident.
In Git's world-view (e.g., in commit headers), an ident name continues
until we get to the "<" of the email (or a "\n" terminates the header
line completely). So if mailinfo is converting rfc2822 headers into Git
ident, I'd expect it to fully remove any quotes that are not intended to
be in the name, and everything after "Author: " up to the newline would
become the name.
It's entirely possible I'm missing something subtle about the design of
mailinfo, though.
-Peff
prev parent reply other threads:[~2016-09-14 5:13 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-12 20:10 git-am includes escape characters from 'From' field Swift Geek
2016-09-13 15:26 ` Jeff King
2016-09-13 23:46 ` [RFC 0/1] de-quote quoted-strings in mailinfo Kevin Daudt
2016-09-13 23:46 ` [RFC 0/1] mailinfo: de-quote quoted-pair in header fields Kevin Daudt
2016-09-14 0:04 ` Junio C Hamano
2016-09-14 4:58 ` Kevin Daudt
2016-09-14 5:09 ` Jeff King
2016-09-14 5:54 ` Junio C Hamano
2016-09-14 16:03 ` Kevin Daudt
2016-09-14 17:43 ` Junio C Hamano
2016-09-14 19:17 ` Jeff King
2016-09-14 19:30 ` Junio C Hamano
2016-09-14 19:38 ` Jeff King
2016-09-15 5:15 ` Kevin Daudt
2016-09-15 7:18 ` Jeff King
2016-09-14 5:13 ` Jeff King [this message]
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
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160914051305.vphknpsikyxi3hg3@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=kevin@lists.ikke.info \
--cc=me@ikke.info \
/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.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).