From: Paolo Bonzini <pbonzini@redhat.com>
To: qemu-devel@nongnu.org
Cc: armbru@redhat.com, thuth@redhat.com, pavel.dovgaluk@ispras.ru
Subject: [Qemu-devel] [PATCH 5/5] get_maintainer: add subsystem to reviewer output
Date: Wed, 3 May 2017 11:43:51 +0200 [thread overview]
Message-ID: <20170503094351.5040-6-pbonzini@redhat.com> (raw)
In-Reply-To: <20170503094351.5040-1-pbonzini@redhat.com>
From: Joe Perches <joe@perches.com>
Reviewer output currently does not include the subsystem
that matched. Add it.
Miscellanea:
o Add a get_subsystem_name routine to centralize this
Cherry picked from Linux commit 2a7cb1dc82fc2a52e747b4c496c13f6575fb1790.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
scripts/get_maintainer.pl | 31 ++++++++++++++++---------------
1 file changed, 16 insertions(+), 15 deletions(-)
diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index bf210c7fa6..63257965ce 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -896,20 +896,29 @@ sub find_ending_index {
return $index;
}
-sub get_maintainer_role {
+sub get_subsystem_name {
my ($index) = @_;
- my $i;
my $start = find_starting_index($index);
- my $end = find_ending_index($index);
- my $role = "unknown";
my $subsystem = $typevalue[$start];
if (length($subsystem) > 20) {
$subsystem = substr($subsystem, 0, 17);
$subsystem =~ s/\s*$//;
$subsystem = $subsystem . "...";
}
+ return $subsystem;
+}
+
+sub get_maintainer_role {
+ my ($index) = @_;
+
+ my $i;
+ my $start = find_starting_index($index);
+ my $end = find_ending_index($index);
+
+ my $role = "unknown";
+ my $subsystem = get_subsystem_name($index);
for ($i = $start + 1; $i < $end; $i++) {
my $tv = $typevalue[$i];
@@ -943,16 +952,7 @@ sub get_maintainer_role {
sub get_list_role {
my ($index) = @_;
- my $i;
- my $start = find_starting_index($index);
- my $end = find_ending_index($index);
-
- my $subsystem = $typevalue[$start];
- if (length($subsystem) > 20) {
- $subsystem = substr($subsystem, 0, 17);
- $subsystem =~ s/\s*$//;
- $subsystem = $subsystem . "...";
- }
+ my $subsystem = get_subsystem_name($index);
if ($subsystem eq "THE REST") {
$subsystem = "";
@@ -1040,7 +1040,8 @@ sub add_categories {
}
}
if ($email_reviewer) {
- push_email_addresses($pvalue, 'reviewer');
+ my $subsystem = get_subsystem_name($i);
+ push_email_addresses($pvalue, "reviewer:$subsystem");
}
} elsif ($ptype eq "T") {
push(@scm, $pvalue);
--
2.12.2
next prev parent reply other threads:[~2017-05-03 9:44 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-03 9:43 [Qemu-devel] [PATCH 0/5] MAINTAINERS/get_maintainers: add support for reviewers Paolo Bonzini
2017-05-03 9:43 ` [Qemu-devel] [PATCH 1/5] MAINTAINERS: Add "R:" tag for self-appointed reviewers Paolo Bonzini
2017-05-03 18:23 ` John Snow
2017-05-03 18:42 ` Paolo Bonzini
2017-05-03 9:43 ` [Qemu-devel] [PATCH 2/5] get_maintainer: Teach get_maintainer.pl about the new "R:" tag Paolo Bonzini
2017-05-03 10:45 ` Thomas Huth
2017-05-03 11:53 ` Paolo Bonzini
2017-05-03 9:43 ` [Qemu-devel] [PATCH 3/5] get_maintainer: it's '--pattern-depth', not '-pattern-depth' Paolo Bonzini
2017-05-03 9:43 ` [Qemu-devel] [PATCH 4/5] get_maintainer: --r (list reviewer) is on by default Paolo Bonzini
2017-05-03 9:43 ` Paolo Bonzini [this message]
2017-05-03 12:29 ` [Qemu-devel] [PATCH 0/5] MAINTAINERS/get_maintainers: add support for reviewers Thomas Huth
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=20170503094351.5040-6-pbonzini@redhat.com \
--to=pbonzini@redhat.com \
--cc=armbru@redhat.com \
--cc=pavel.dovgaluk@ispras.ru \
--cc=qemu-devel@nongnu.org \
--cc=thuth@redhat.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).