From: Kevin Wolf <kwolf@redhat.com>
To: Stefan Hajnoczi <stefanha@gmail.com>
Cc: qemu-devel <qemu-devel@nongnu.org>
Subject: Re: Maintainers, please add Message-Id: when merging patches
Date: Thu, 23 Jan 2020 18:18:57 +0100 [thread overview]
Message-ID: <20200123171857.GC5021@linux.fritz.box> (raw)
In-Reply-To: <20200122122831.GB13482@linux.fritz.box>
Am 22.01.2020 um 13:28 hat Kevin Wolf geschrieben:
> Am 22.01.2020 um 13:02 hat Stefan Hajnoczi geschrieben:
> > Around 66% of qemu.git commits since v4.1.0 include a Message-Id: tag. Hooray!
> >
> > Message-Id: references the patch email that a commit was merged from.
> > This information is helpful to anyone wishing to refer back to email
> > discussions and patch series.
> >
> > Please use git-am(1) -m/--message-id or set am.messageid in your git-config(1).
>
> I've had -m in my scripts for a while (last time someone asked me to
> make the change, I guess), but it wasn't effective, because my .muttrc
> has 'set pipe_decode' enabled, which doesn't only decode the output, but
> also throws away most headers.
>
> I seem to remember that this was necessary at some point because
> otherwise some mails just wouldn't apply. Maybe 'git am' works better
> these days and can actually parse the mails that used to give me
> problems. I'll give it a try and disable pipe_decode.
Here is the first patch for which it failed for me:
Message-ID: <20200123124357.124019-1-felipe@nutanix.com>
The problem seems to be related to line endings because the patch that
git-apply sees eventually has "\r\n" whereas the file to be patched has
only "\n".
If I understand correctly (this is a bit of guesswork after reading man
pages and trying out a few options), git-mailsplit would normally get
rid of the "\r". However, this specific patch email is base64 encoded,
so the encoded "\r" characters survive this stage.
git-mailinfo later decodes the email, but doesn't seem to do anything
about "\r" again, so it survives this one as well. This means feeding a
patch with the wrong line endings to git-apply, which just fails.
Any suggestion how to fix this? (For this patch, I just enabled
pipe_decode again, so no Message-Id tag for it.)
Kevin
next prev parent reply other threads:[~2020-01-23 20:26 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-22 12:02 Maintainers, please add Message-Id: when merging patches Stefan Hajnoczi
2020-01-22 12:28 ` Kevin Wolf
2020-01-23 17:18 ` Kevin Wolf [this message]
2020-01-23 21:23 ` Laszlo Ersek
2020-01-24 10:58 ` Stefan Hajnoczi
2020-01-22 12:30 ` Alex Bennée
2020-01-22 13:51 ` Cornelia Huck
2020-01-22 14:10 ` Laszlo Ersek
2020-01-22 18:56 ` Alex Bennée
2020-01-22 19:07 ` Cornelia Huck
2020-01-23 9:41 ` Laszlo Ersek
2020-01-22 14:26 ` Gerd Hoffmann
2020-01-23 8:27 ` Markus Armbruster
2020-01-23 11:17 ` Stefan Hajnoczi
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=20200123171857.GC5021@linux.fritz.box \
--to=kwolf@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.com \
/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).