From nobody Fri Apr 26 18:05:35 2024 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org ARC-Seal: i=1; a=rsa-sha256; t=1567596683; cv=none; d=zoho.com; s=zohoarc; b=QiN09c/ARa1UZ163L2evvS3hMj3gLLIS5vl0Q+QXbWG9+3UEVX3OzbucFDQ2xJsdcR3K7TdG0kM8n6jHp6CkATSJ+AJaJli3DHdtLjqNV3IRWyVql4tUnxbA0ZIcuQ8LILjK7GrRCFtZN7/QRwXqUu7xX+BhHw4JbeTq4uFHr2E= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1567596683; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=Rl4xOsFd2jvSlTgXDMXhd9iCM+LxEVD6qbifaXLMVas=; b=Q8plcwmg5hwshiuUKNnlZ9OPchGW/6NTt5fhSWhlFyY5WbWO0ne8W8SWNAB/QBSNW6PzWTLVClVjyLqbddzn8eJRV96XNy5Ouak4l7v+CFrhVH8gDo6nJfNW8WZ77uxh++vaK1NsnlABJFteUp0fORVTCSn2FUG2oa139drPm6Y= ARC-Authentication-Results: i=1; mx.zoho.com; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1567596683768350.37627945772203; Wed, 4 Sep 2019 04:31:23 -0700 (PDT) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUR-0006S6-NI; Wed, 04 Sep 2019 11:30:19 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUQ-0006RT-Cw for xen-devel@lists.xenproject.org; Wed, 04 Sep 2019 11:30:18 +0000 Received: from mail.xenproject.org (unknown [104.130.215.37]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 5ef17406-cf07-11e9-978d-bc764e2007e4; Wed, 04 Sep 2019 11:30:17 +0000 (UTC) Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUO-0005c2-7t; Wed, 04 Sep 2019 11:30:16 +0000 Received: from localhost ([127.0.0.1] helo=localhost.localdomain) by xenbits.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUO-0004TJ-0H; Wed, 04 Sep 2019 11:30:16 +0000 X-Inumbo-ID: 5ef17406-cf07-11e9-978d-bc764e2007e4 From: Lars Kurth To: xen-devel@lists.xenproject.org Date: Wed, 4 Sep 2019 12:30:08 +0100 Message-Id: <0944333a4a0b503789d10afa63f8229bd0441290.1567596460.git-series.lars.kurth@citrix.com> X-Mailer: git-send-email 2.13.0 In-Reply-To: References: In-Reply-To: References: Subject: [Xen-devel] [PATCH v4 1/3] Remove hardcoding from scripts/add_maintainers.pl X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Lars Kurth , Stefano Stabellini , Wei Liu , Konrad Rzeszutek Wilk , George Dunlap , Andrew Cooper , Ian Jackson , Tim Deegan , Julien Grall , Jan Beulich MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" Instead of using a hardcoded location, inherit the location from $0 Signed-off-by: Lars Kurth Acked-by: Julien Grall --- scripts/add_maintainers.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/add_maintainers.pl b/scripts/add_maintainers.pl index 09e9f66..5a6d0f6 100755 --- a/scripts/add_maintainers.pl +++ b/scripts/add_maintainers.pl @@ -26,9 +26,9 @@ sub insert ($$$$); sub hastag ($$); =20 # Tool Variables -my $get_maintainer =3D "./scripts/get_maintainer.pl"; - my $tool =3D $0; +my $get_maintainer =3D $tool; +$get_maintainer =3D~ s/add_maintainers/get_maintainer/; my $usage =3D < Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 15675966875211019.2001181374062; Wed, 4 Sep 2019 04:31:27 -0700 (PDT) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUT-0006TG-5T; Wed, 04 Sep 2019 11:30:21 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUS-0006SN-0d for xen-devel@lists.xenproject.org; Wed, 04 Sep 2019 11:30:20 +0000 Received: from mail.xenproject.org (unknown [104.130.215.37]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 60088bae-cf07-11e9-b299-bc764e2007e4; Wed, 04 Sep 2019 11:30:19 +0000 (UTC) Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUP-0005c8-GV; Wed, 04 Sep 2019 11:30:17 +0000 Received: from localhost ([127.0.0.1] helo=localhost.localdomain) by xenbits.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUP-0004TJ-AI; Wed, 04 Sep 2019 11:30:17 +0000 X-Inumbo-ID: 60088bae-cf07-11e9-b299-bc764e2007e4 From: Lars Kurth To: xen-devel@lists.xenproject.org Date: Wed, 4 Sep 2019 12:30:09 +0100 Message-Id: X-Mailer: git-send-email 2.13.0 In-Reply-To: References: In-Reply-To: References: Subject: [Xen-devel] [PATCH v4 2/3] Add V section entry to allow identification of Xen MAINTAINERS file X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Lars Kurth , Stefano Stabellini , Wei Liu , Konrad Rzeszutek Wilk , George Dunlap , Andrew Cooper , Ian Jackson , Tim Deegan , Julien Grall , Jan Beulich MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" This change provides sufficient information to allow get_maintainer.pl / add_maintainers.pl scripts to be run on xen sister repositories such as mini-os.git, osstest.git, etc A suggested template for sister repositories of Xen is =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D This file follows the same conventions as outlined in xen.git:MAINTAINERS. Please refer to the file in xen.git for more information. THE REST M: MAINTAINER1 M: MAINTAINER2 L: xen-devel@lists.xenproject.org S: Supported F: * F: */ V: xen-maintainers-1 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D Signed-off-by: Lars Kurth Acked-by: Jan Beulich Acked-by: Julien Grall --- MAINTAINERS | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 77413e0..bb3da43 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -97,6 +97,9 @@ Descriptions of section entries: matches patches or files that contain one or more of the words printk, pr_info or pr_err One regex pattern per line. Multiple K: lines acceptable. + V: Version identifier that must be under THE REST and follows + the format: + xen-maintainers- =20 =20 The meaning of nesting: @@ -541,3 +544,4 @@ L: xen-devel@lists.xenproject.org S: Supported F: * F: */ +V: xen-maintainers-1 --=20 git-series 0.9.1 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel From nobody Fri Apr 26 18:05:35 2024 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org ARC-Seal: i=1; a=rsa-sha256; t=1567596687; cv=none; d=zoho.com; s=zohoarc; b=DAT2hkFzDXZDYoO2lSQwUuq6DXYoFCGikni++8RXJp8PHeAm29dy6YPIhk+2VGLa6gs5C4fLi5vvHwqomvrglWtNxScdQE4yRiyE5aq3OWabBkV15C10Z0unLWTp3Nf45aSUBOckTHgz9YLY7ma6+U/3OtNbQ1/4OQ//Cgp+dq0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1567596687; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=NGO4dmF/l9ge3TFDpjrOvZi0Y5ACVALNlV9AFHV6Y8s=; b=Q+QdeMXOll03uOTPhbmVAbHVZoGMLY0S5vIczbx0OUkfJKE5vS6zm2cGwNT3rqz7iy2thBHXpHelN87iysgD3LN0m7Ps3refHb8g6iDWS+ZOT47Wy2Zvz4Hlkqv6RWYQMhS83hhvVrZOyXK+CZpmKgtms6ZD5UxYd09aGeUufVg= ARC-Authentication-Results: i=1; mx.zoho.com; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1567596687210536.6700605871943; Wed, 4 Sep 2019 04:31:27 -0700 (PDT) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUX-0006VO-Fn; Wed, 04 Sep 2019 11:30:25 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUW-0006Uw-9j for xen-devel@lists.xenproject.org; Wed, 04 Sep 2019 11:30:24 +0000 Received: from mail.xenproject.org (unknown [104.130.215.37]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 604baa06-cf07-11e9-978d-bc764e2007e4; Wed, 04 Sep 2019 11:30:20 +0000 (UTC) Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUQ-0005cF-QR; Wed, 04 Sep 2019 11:30:18 +0000 Received: from localhost ([127.0.0.1] helo=localhost.localdomain) by xenbits.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i5TUQ-0004TJ-KZ; Wed, 04 Sep 2019 11:30:18 +0000 X-Inumbo-ID: 604baa06-cf07-11e9-978d-bc764e2007e4 From: Lars Kurth To: xen-devel@lists.xenproject.org Date: Wed, 4 Sep 2019 12:30:10 +0100 Message-Id: <0b543489f930ab966d916e47a738d77de793b8c4.1567596460.git-series.lars.kurth@citrix.com> X-Mailer: git-send-email 2.13.0 In-Reply-To: References: In-Reply-To: References: Subject: [Xen-devel] [PATCH v4 3/3] Add logic to use V section entry in THE REST for identifying xen trees X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Lars Kurth , Stefano Stabellini , Wei Liu , Konrad Rzeszutek Wilk , George Dunlap , Andrew Cooper , Ian Jackson , Tim Deegan , Julien Grall , Jan Beulich MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" Specifically: * Move check until after the MAINTAINERS file has been read * Add get_xen_maintainers_file_version() for check * Remove top_of_tree as not needed any more * Fail with extended error message when used out of tree Signed-off-by: Lars Kurth Acked-by: Ian Jackson --- scripts/get_maintainer.pl | 57 ++++++++++++++++++++++++---------------- 1 file changed, 35 insertions(+), 22 deletions(-) diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl index 174dfb7..2e661f4 100755 --- a/scripts/get_maintainer.pl +++ b/scripts/get_maintainer.pl @@ -265,11 +265,6 @@ if ($email && die "$P: Please select at least 1 email option\n"; } =20 -if (!top_of_tree($xen_path)) { - die "$P: The current directory does not appear to be " - . "a Xen source tree.\n"; -} - ## Read MAINTAINERS for type/value pairs =20 my @typevalue =3D (); @@ -311,6 +306,16 @@ while (<$maint>) { } close($maint); =20 +# Check whether we have a V entry under the REST +# and use it to get the file's version number +my $maintainers_file_version =3D get_xen_maintainers_file_version(); +if (!$maintainers_file_version) { + die "$P: the MAINTAINERS file ". + "in the current directory does not appear to be from ". + "the xen.git source tree or a sister tree.\n\n". + "A 'V: xen-maintainers-' entry under THE REST ". + "is needed to identify a Xen MAINTAINERS file.\n\n"; +} =20 # # Read mail address map @@ -564,6 +569,31 @@ sub range_has_maintainer { return 0; } =20 +sub get_xen_maintainers_file_version { + my $tvi =3D find_first_section(); + + while ($tvi < @typevalue) { + my $start =3D find_starting_index($tvi); + my $end =3D find_ending_index($tvi); + my $i; + + for ($i =3D $start; $i < $end; $i++) { + my $line =3D $typevalue[$i]; + if ($line =3D~ m/^V:\s*(.*)/) { + # Note that get_maintainer_role() requires processing + # of more of the file. So do it directly + if ($typevalue[$start] eq "THE REST") { + if ($line =3D~ m/xen-maintainers-(.*)/) { + return $1; + } + } + } + } + $tvi =3D $end + 1; + } + return 0; +} + sub get_maintainers { %email_hash_name =3D (); %email_hash_address =3D (); @@ -867,23 +897,6 @@ Notes: EOT } =20 -sub top_of_tree { - my ($xen_path) =3D @_; - - if ($xen_path ne "" && substr($xen_path,length($xen_path)-1,1) ne "/")= { - $xen_path .=3D "/"; - } - if ( (-f "${xen_path}COPYING") - && (-f "${xen_path}MAINTAINERS") - && (-f "${xen_path}Makefile") - && (-d "${xen_path}docs") - && (-f "${xen_path}CODING_STYLE") - && (-d "${xen_path}xen")) { - return 1; - } - return 0; -} - sub parse_email { my ($formatted_email) =3D @_; =20 --=20 git-series 0.9.1 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel