Xen-Devel Archive on lore.kernel.org
 help / color / Atom feed
* [Xen-devel] [PATCH v2] get_maintainer: Improve patch recognition
@ 2019-06-18 11:12 Volodymyr Babchuk
  2019-07-07 17:26 ` Julien Grall
  0 siblings, 1 reply; 2+ messages in thread
From: Volodymyr Babchuk @ 2019-06-18 11:12 UTC (permalink / raw)
  To: xen-devel, Julien Grall
  Cc: Stefano Stabellini, Wei Liu, Konrad Rzeszutek Wilk,
	George Dunlap, Andrew Cooper, Ian Jackson, Tim Deegan,
	Jan Beulich, Heinrich Schuchardt, Joe Perches, Volodymyr Babchuk

From: Joe Perches <joe@perches.com>

There are mode change and rename only patches that are unrecognized
by the get_maintainer.pl script.

Recognize them.

[ Linux commit 0455c74788fd5aad4399f00e3fbbb7e87450ca58 ]

Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
CC: Julien Grall <julien.grall@arm.com>
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Volodymyr Babchuk <volodymyr_babchuk@epam.com>
---

 Changes wrt to v1:
 - Updated commit message - add Linux commit id

 scripts/get_maintainer.pl | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index d528da738c..174dfb7e40 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -445,7 +445,18 @@ foreach my $file (@ARGV) {
 
 	while (<$patch>) {
 	    my $patch_line = $_;
-	    if (m/^\+\+\+\s+(\S+)/ or m/^---\s+(\S+)/) {
+	    if (m/^ mode change [0-7]+ => [0-7]+ (\S+)\s*$/) {
+		my $filename = $1;
+		push(@files, $filename);
+	    } elsif (m/^rename (?:from|to) (\S+)\s*$/) {
+		my $filename = $1;
+		push(@files, $filename);
+	    } elsif (m/^diff --git a\/(\S+) b\/(\S+)\s*$/) {
+		my $filename1 = $1;
+		my $filename2 = $2;
+		push(@files, $filename1);
+		push(@files, $filename2);
+	    } elsif (m/^\+\+\+\s+(\S+)/ or m/^---\s+(\S+)/) {
 		my $filename = $1;
 		if ($1 ne "/dev/null") { #Ignore the no-file placeholder
 		    $filename =~ s@^[^/]*/@@;
-- 
2.21.0

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Xen-devel] [PATCH v2] get_maintainer: Improve patch recognition
  2019-06-18 11:12 [Xen-devel] [PATCH v2] get_maintainer: Improve patch recognition Volodymyr Babchuk
@ 2019-07-07 17:26 ` Julien Grall
  0 siblings, 0 replies; 2+ messages in thread
From: Julien Grall @ 2019-07-07 17:26 UTC (permalink / raw)
  To: Volodymyr Babchuk, xen-devel
  Cc: Stefano Stabellini, Wei Liu, Konrad Rzeszutek Wilk,
	George Dunlap, Andrew Cooper, Ian Jackson, Tim Deegan,
	Jan Beulich, Heinrich Schuchardt, Joe Perches

Hi,

On 6/18/19 12:12 PM, Volodymyr Babchuk wrote:
> From: Joe Perches <joe@perches.com>
> 
> There are mode change and rename only patches that are unrecognized
> by the get_maintainer.pl script.
> 
> Recognize them.
> 
> [ Linux commit 0455c74788fd5aad4399f00e3fbbb7e87450ca58 ]
> 
> Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
> CC: Julien Grall <julien.grall@arm.com>
> Signed-off-by: Joe Perches <joe@perches.com>
> Signed-off-by: Volodymyr Babchuk <volodymyr_babchuk@epam.com>

This looks good to me.

Acked-by: Julien Grall <julien.grall@arm.com>

Cheers,

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-18 11:12 [Xen-devel] [PATCH v2] get_maintainer: Improve patch recognition Volodymyr Babchuk
2019-07-07 17:26 ` Julien Grall

Xen-Devel Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/xen-devel/0 xen-devel/git/0.git
	git clone --mirror https://lore.kernel.org/xen-devel/1 xen-devel/git/1.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 xen-devel xen-devel/ https://lore.kernel.org/xen-devel \
		xen-devel@lists.xenproject.org xen-devel@archiver.kernel.org
	public-inbox-index xen-devel


Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.xenproject.lists.xen-devel


AGPL code for this site: git clone https://public-inbox.org/ public-inbox