qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PULL 0/2] Net patches


From: Eric Blake
Subject: Re: [Qemu-devel] [PULL 0/2] Net patches
Date: Mon, 26 Mar 2018 11:54:27 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0

On 03/26/2018 11:12 AM, Peter Maydell wrote:

but it would be nice if we can improve our tooling to prevent future
instances of the recurring problem.

Yuck. (Maybe we should try whatever the other workaround for
this SPF vs mailing lists problem is?)

If you can suggest a patch to my apply-pullreq script I'm
happy to change it to reject these at pull application time.

https://git.linaro.org/people/peter.maydell/misc-scripts.git/tree/apply-pullreq

My first quick attempt:

diff --git i/apply-pullreq w/apply-pullreq
index a5528e4..9ae4b8f 100755
--- i/apply-pullreq
+++ w/apply-pullreq
@@ -104,6 +104,12 @@ if git diff master..staging | grep -q 'Subproject commit'; then echo "WARNING: pull appears to include submodule update, please check it!"
 fi

+# Check whether any authors needs to be corrected after SPF rewrites
+if git shortlog address@hidden master..staging | grep .; then
+    echo "ERROR: pull request includes commits attributed to list"
+    exit 1
+fi
+
 # This should exit with an error status if any of the sub-builds fails.
 parallel-buildtest


Hmm, on re-reading that, I wonder if shortlog will do the right thing when a .mailmap entry exists. I'm trying to make sure we don't have to go lower-level with use of 'git log --format=%ae' (vs. --format=%aE and/or log --use-mailmap).

/me goes and experiments with:

diff --git i/.mailmap w/.mailmap
index cf689b9ec99..a90d7deebe6 100644
--- i/.mailmap
+++ w/.mailmap
@@ -10,6 +10,7 @@ Edgar E. Iglesias <address@hidden> edgar_igl <address@hidden Fabrice Bellard <address@hidden> bellard <address@hidden>
 James Hogan <address@hidden> <address@hidden>
Jocelyn Mayer <address@hidden> j_mayer <address@hidden> +Julia Suvorova <<address@hidden> Julia Suvorova via Qemu-devel <address@hidden> Paul Brook <address@hidden> pbrook <address@hidden>
 Paul Burton <address@hidden> <address@hidden>
 Paul Burton <address@hidden> <address@hidden>

Yay - shortlog still lists Julia's commit even with the mailmap in place (but with a better spelling of her name), so I don't need to try anything fancier. I'll post a separate patch for mailmap, then leave it up to you whether to incorporate my shortlog snippet above into your build script.

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org



reply via email to

[Prev in Thread] Current Thread [Next in Thread]