[Qemu-devel] [PATCH 1/5] Add a git-publish configuration file

There is a newer version of this series
[Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Stefan Hajnoczi 7 years, 2 months ago
From: Fam Zheng <famz@redhat.com>

git-publish [1] is a convenient tool to send patches and has been
popular among QEMU developers.  Recently it has been made available in
Fedora official repo thanks to Stefan's work.

One nice feature of the tool is a per-project configuration with
profiles, especially in which the cccmd option is a handy method to
create the Cc list.

[1]: https://github.com/stefanha/git-publish

Signed-off-by: Fam Zheng <famz@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-id: 20180205054725.25634-2-famz@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
 .gitpublish | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 58 insertions(+)
 create mode 100644 .gitpublish

diff --git a/.gitpublish b/.gitpublish
new file mode 100644
index 0000000000..ed48f6e52c
--- /dev/null
+++ b/.gitpublish
@@ -0,0 +1,58 @@
+#
+# Common git-publish profiles that can be used to send patches to QEMU upstream.
+#
+# See https://github.com/stefanha/git-publish for more information
+#
+[gitpublishprofile "default"]
+base = master
+prefix = PATCH
+to = qemu-devel@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
+
+[gitpublishprofile "rfc"]
+base = master
+prefix = RFC PATCH
+to = qemu-devel@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
+
+[gitpublishprofile "stable"]
+base = master
+prefix = PATCH
+to = qemu-devel@nongnu.org
+cc = qemu-stable@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
+
+[gitpublishprofile "trivial"]
+base = master
+prefix = PATCH
+to = qemu-devel@nongnu.org
+cc = qemu-trivial@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
+
+[gitpublishprofile "block"]
+base = master
+prefix = PATCH
+to = qemu-devel@nongnu.org
+cc = qemu-block@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
+
+[gitpublishprofile "arm"]
+base = master
+prefix = PATCH
+to = qemu-devel@nongnu.org
+cc = qemu-arm@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
+
+[gitpublishprofile "s390"]
+base = master
+prefix = PATCH
+to = qemu-devel@nongnu.org
+cc = qemu-s390@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
+
+[gitpublishprofile "ppc"]
+base = master
+prefix = PATCH
+to = qemu-devel@nongnu.org
+cc = qemu-ppc@nongnu.org
+cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
-- 
2.14.3


Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Daniel P. Berrangé 7 years, 2 months ago
On Tue, Feb 13, 2018 at 05:34:25PM +0000, Stefan Hajnoczi wrote:
> From: Fam Zheng <famz@redhat.com>
> 
> git-publish [1] is a convenient tool to send patches and has been
> popular among QEMU developers.  Recently it has been made available in
> Fedora official repo thanks to Stefan's work.
> 
> One nice feature of the tool is a per-project configuration with
> profiles, especially in which the cccmd option is a handy method to
> create the Cc list.
> 
> [1]: https://github.com/stefanha/git-publish
> 
> Signed-off-by: Fam Zheng <famz@redhat.com>
> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> Message-id: 20180205054725.25634-2-famz@redhat.com
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
> ---
>  .gitpublish | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 58 insertions(+)
>  create mode 100644 .gitpublish
> 
> diff --git a/.gitpublish b/.gitpublish
> new file mode 100644
> index 0000000000..ed48f6e52c
> --- /dev/null
> +++ b/.gitpublish
> @@ -0,0 +1,58 @@
> +#
> +# Common git-publish profiles that can be used to send patches to QEMU upstream.
> +#
> +# See https://github.com/stefanha/git-publish for more information
> +#
> +[gitpublishprofile "default"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "rfc"]
> +base = master
> +prefix = RFC PATCH
> +to = qemu-devel@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "stable"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-stable@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "trivial"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-trivial@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "block"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-block@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null

Why is a custom entry needed for block here (and other things
below).   Won't running get_maintainer.pl already correctly
report when a patch needs cc'ing to qemu-block@nongnu.org
based on MAINTAINER rules ?


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|

Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Fam Zheng 7 years, 2 months ago
On Tue, 02/13 18:09, Daniel P. Berrangé wrote:
> On Tue, Feb 13, 2018 at 05:34:25PM +0000, Stefan Hajnoczi wrote:
> > From: Fam Zheng <famz@redhat.com>
> > 
> > git-publish [1] is a convenient tool to send patches and has been
> > popular among QEMU developers.  Recently it has been made available in
> > Fedora official repo thanks to Stefan's work.
> > 
> > One nice feature of the tool is a per-project configuration with
> > profiles, especially in which the cccmd option is a handy method to
> > create the Cc list.
> > 
> > [1]: https://github.com/stefanha/git-publish
> > 
> > Signed-off-by: Fam Zheng <famz@redhat.com>
> > Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> > Message-id: 20180205054725.25634-2-famz@redhat.com
> > Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
> > ---
> >  .gitpublish | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> >  1 file changed, 58 insertions(+)
> >  create mode 100644 .gitpublish
> > 
> > diff --git a/.gitpublish b/.gitpublish
> > new file mode 100644
> > index 0000000000..ed48f6e52c
> > --- /dev/null
> > +++ b/.gitpublish
> > @@ -0,0 +1,58 @@
> > +#
> > +# Common git-publish profiles that can be used to send patches to QEMU upstream.
> > +#
> > +# See https://github.com/stefanha/git-publish for more information
> > +#
> > +[gitpublishprofile "default"]
> > +base = master
> > +prefix = PATCH
> > +to = qemu-devel@nongnu.org
> > +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> > +
> > +[gitpublishprofile "rfc"]
> > +base = master
> > +prefix = RFC PATCH
> > +to = qemu-devel@nongnu.org
> > +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> > +
> > +[gitpublishprofile "stable"]
> > +base = master
> > +prefix = PATCH
> > +to = qemu-devel@nongnu.org
> > +cc = qemu-stable@nongnu.org
> > +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> > +
> > +[gitpublishprofile "trivial"]
> > +base = master
> > +prefix = PATCH
> > +to = qemu-devel@nongnu.org
> > +cc = qemu-trivial@nongnu.org
> > +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> > +
> > +[gitpublishprofile "block"]
> > +base = master
> > +prefix = PATCH
> > +to = qemu-devel@nongnu.org
> > +cc = qemu-block@nongnu.org
> > +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> 
> Why is a custom entry needed for block here (and other things
> below).   Won't running get_maintainer.pl already correctly
> report when a patch needs cc'ing to qemu-block@nongnu.org
> based on MAINTAINER rules ?

Yeah, dropping them should be fine. What do you think, Stefan?

Fam

Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Stefan Hajnoczi 7 years, 2 months ago
On Wed, Feb 14, 2018 at 09:01:11AM +0800, Fam Zheng wrote:
> On Tue, 02/13 18:09, Daniel P. Berrangé wrote:
> > On Tue, Feb 13, 2018 at 05:34:25PM +0000, Stefan Hajnoczi wrote:
> > > +[gitpublishprofile "block"]
> > > +base = master
> > > +prefix = PATCH
> > > +to = qemu-devel@nongnu.org
> > > +cc = qemu-block@nongnu.org
> > > +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> > 
> > Why is a custom entry needed for block here (and other things
> > below).   Won't running get_maintainer.pl already correctly
> > report when a patch needs cc'ing to qemu-block@nongnu.org
> > based on MAINTAINER rules ?
> 
> Yeah, dropping them should be fine. What do you think, Stefan?

scripts/get_maintainer.pl only works when patches touch files associated
with qemu-block@nongnu.org in MAINTAINERS.  It would be
counter-intuitive for --profile block to not include
qemu-block@nongnu.org, so I think these entries do serve a purpose.

On the other hand, I personally just use --cc qemu-block instead of a
profile for this.  I'll probably only use the default profile.

Fam, if you want it dropped, let me know.  Otherwise, we can leave it
in if there is no further discussion.

Stefan
Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Fam Zheng 7 years, 2 months ago
On Wed, Feb 14, 2018 at 9:34 PM, Stefan Hajnoczi <stefanha@redhat.com> wrote:
> On Wed, Feb 14, 2018 at 09:01:11AM +0800, Fam Zheng wrote:
> Fam, if you want it dropped, let me know.  Otherwise, we can leave it
> in if there is no further discussion.

Yeah, I think we can drop block/arm/s390/ppc and rely on get_maintainer.pl here.

Fam

Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Eric Blake 7 years, 2 months ago
On 02/14/2018 07:34 AM, Stefan Hajnoczi wrote:
> On Wed, Feb 14, 2018 at 09:01:11AM +0800, Fam Zheng wrote:
>> On Tue, 02/13 18:09, Daniel P. Berrangé wrote:
>>> On Tue, Feb 13, 2018 at 05:34:25PM +0000, Stefan Hajnoczi wrote:
>>>> +[gitpublishprofile "block"]
>>>> +base = master
>>>> +prefix = PATCH
>>>> +to = qemu-devel@nongnu.org
>>>> +cc = qemu-block@nongnu.org
>>>> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
>>>
>>> Why is a custom entry needed for block here (and other things
>>> below).   Won't running get_maintainer.pl already correctly
>>> report when a patch needs cc'ing to qemu-block@nongnu.org
>>> based on MAINTAINER rules ?
>>
>> Yeah, dropping them should be fine. What do you think, Stefan?
> 
> scripts/get_maintainer.pl only works when patches touch files associated
> with qemu-block@nongnu.org in MAINTAINERS.  It would be
> counter-intuitive for --profile block to not include
> qemu-block@nongnu.org, so I think these entries do serve a purpose.

More precisely, the cover letter does not touch any files, and git 
doesn't know how to automatically cc the cover letter to any recipient 
of any of the rest of the series.  Having these entries ensures that the 
cover letter goes to the right list (on the other hand, git publish 
itself could be taught to be smarter about cc'ing the cover letter to 
every email scraped from later in the series, even if git send-email 
can't do that yet).

> 
> On the other hand, I personally just use --cc qemu-block instead of a
> profile for this.  I'll probably only use the default profile.
> 
> Fam, if you want it dropped, let me know.  Otherwise, we can leave it
> in if there is no further discussion.
> 
> Stefan
> 

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

Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Paolo Bonzini 7 years, 2 months ago
On 13/02/2018 19:09, Daniel P. Berrangé wrote:
> Why is a custom entry needed for block here (and other things
> below).   Won't running get_maintainer.pl already correctly
> report when a patch needs cc'ing to qemu-block@nongnu.org
> based on MAINTAINER rules ?

Sometimes you want to CC block people even on a non-block patch, for
example if you want their opinion about using the API.

We should probably add at least arm and ppc profiles, too.

> --nogit --nogit-fallback

QEMU's getmaintainer (unlike the Linux version!) already tries to avoid
falling back to git if a maintainer is listed.  Are these options necessary?

Paolo

Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Paolo Bonzini 7 years, 2 months ago
On 14/02/2018 15:08, Paolo Bonzini wrote:
> On 13/02/2018 19:09, Daniel P. Berrangé wrote:
>> Why is a custom entry needed for block here (and other things
>> below).   Won't running get_maintainer.pl already correctly
>> report when a patch needs cc'ing to qemu-block@nongnu.org
>> based on MAINTAINER rules ?
> 
> Sometimes you want to CC block people even on a non-block patch, for
> example if you want their opinion about using the API.
> 
> We should probably add at least arm and ppc profiles, too.

Nevermind, they were there below qemu-block.

Paolo

>> --nogit --nogit-fallback
> 
> QEMU's getmaintainer (unlike the Linux version!) already tries to avoid
> falling back to git if a maintainer is listed.  Are these options necessary?
> 
> Paolo
> 


Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Fam Zheng 7 years, 2 months ago
On Wed, 02/14 15:08, Paolo Bonzini wrote:
> On 13/02/2018 19:09, Daniel P. Berrangé wrote:
> > Why is a custom entry needed for block here (and other things
> > below).   Won't running get_maintainer.pl already correctly
> > report when a patch needs cc'ing to qemu-block@nongnu.org
> > based on MAINTAINER rules ?
> 
> Sometimes you want to CC block people even on a non-block patch, for
> example if you want their opinion about using the API.
> 
> We should probably add at least arm and ppc profiles, too.
> 
> > --nogit --nogit-fallback
> 
> QEMU's getmaintainer (unlike the Linux version!) already tries to avoid
> falling back to git if a maintainer is listed.  Are these options necessary?
> 

Falling back to git is usually more noisy than useful even when a maintainer is
not listed, in my past experience. That's why I don't use it myself and propose
such here. But I'm open to different opinions.

Fam

Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Philippe Mathieu-Daudé 7 years, 2 months ago
On 02/13/2018 02:34 PM, Stefan Hajnoczi wrote:
> From: Fam Zheng <famz@redhat.com>
> 
> git-publish [1] is a convenient tool to send patches and has been
> popular among QEMU developers.  Recently it has been made available in
> Fedora official repo thanks to Stefan's work.

Also Debian:
https://packages.debian.org/sid/git-publish

> 
> One nice feature of the tool is a per-project configuration with
> profiles, especially in which the cccmd option is a handy method to
> create the Cc list.
> 
> [1]: https://github.com/stefanha/git-publish
> 
> Signed-off-by: Fam Zheng <famz@redhat.com>
> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> Message-id: 20180205054725.25634-2-famz@redhat.com
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
> ---
>  .gitpublish | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 58 insertions(+)
>  create mode 100644 .gitpublish
> 
> diff --git a/.gitpublish b/.gitpublish
> new file mode 100644
> index 0000000000..ed48f6e52c
> --- /dev/null
> +++ b/.gitpublish
> @@ -0,0 +1,58 @@
> +#
> +# Common git-publish profiles that can be used to send patches to QEMU upstream.
> +#
> +# See https://github.com/stefanha/git-publish for more information
> +#
> +[gitpublishprofile "default"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "rfc"]
> +base = master
> +prefix = RFC PATCH
> +to = qemu-devel@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "stable"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-stable@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "trivial"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-trivial@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "block"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-block@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "arm"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-arm@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "s390"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-s390@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> +
> +[gitpublishprofile "ppc"]
> +base = master
> +prefix = PATCH
> +to = qemu-devel@nongnu.org
> +cc = qemu-ppc@nongnu.org
> +cccmd = scripts/get_maintainer.pl --noroles --norolestats --nogit --nogit-fallback 2>/dev/null
> 

Re: [Qemu-devel] [PATCH 1/5] Add a git-publish configuration file
Posted by Fam Zheng 7 years, 2 months ago
On Wed, 02/14 14:37, Philippe Mathieu-Daudé wrote:
> On 02/13/2018 02:34 PM, Stefan Hajnoczi wrote:
> > From: Fam Zheng <famz@redhat.com>
> > 
> > git-publish [1] is a convenient tool to send patches and has been
> > popular among QEMU developers.  Recently it has been made available in
> > Fedora official repo thanks to Stefan's work.
> 
> Also Debian:
> https://packages.debian.org/sid/git-publish

Thank you for doing that! I will add the pointer.

Fam