From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mx.groups.io with SMTP id smtpd.web10.156494.1669743197967137614 for ; Tue, 29 Nov 2022 09:33:18 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@linux.microsoft.com header.s=default header.b=lgJLwJKq; spf=pass (domain: linux.microsoft.com, ip: 13.77.154.182, mailfrom: mikuback@linux.microsoft.com) Received: from localhost.localdomain (unknown [47.201.8.94]) by linux.microsoft.com (Postfix) with ESMTPSA id BC86E20B717A; Tue, 29 Nov 2022 09:33:16 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com BC86E20B717A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1669743197; bh=Lb+5L4PhHZZjakBH6WbhSItvd2fBRzGnqtpcLtI8isk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lgJLwJKq3KN+8B2JqkFQANnYS4uOcm1j3zZp7KTz8Hhm02mEEs/3icuPTPJee3KIT d5fQ9NCDAHcg6bJVTbjsOH7z8SfdNKfjbTNJDTSaDda5AWD9GLu6iKX5/YawDRGfRb QHuAqlOiUAUisTXEugndF4IIO07TwmQsi5aa4bDk= From: "Michael Kubacki" To: devel@edk2.groups.io Cc: Bob Feng , Liming Gao , Michael D Kinney , Sean Brogan , Yuwei Chen Subject: [PATCH v2 02/12] BaseTools/PatchCheck.py: Add PCCTS to tab exemption list Date: Tue, 29 Nov 2022 12:32:36 -0500 Message-Id: <20221129173246.2182-3-mikuback@linux.microsoft.com> X-Mailer: git-send-email 2.28.0.windows.1 In-Reply-To: <20221129173246.2182-1-mikuback@linux.microsoft.com> References: <20221129173246.2182-1-mikuback@linux.microsoft.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Michael Kubacki Purdue Compiler Construction Tool Set (PCCTS) source code was copied/ pasted into BaseTools/Source/C/VfrCompile/Pccts/. The code contains tab characters instead of spaces. PatchCheck.py gives an error on modifications to files that contain tabs. This change adds that directory to the pre-existing list of directories in which tab checks are ignored in PatchCheck.py. The goal of my upcoming change there is not to mix tabs and spaces but to fix a bug while preserving its current formatting characters. Cc: Bob Feng Cc: Liming Gao Cc: Michael D Kinney Cc: Sean Brogan Cc: Yuwei Chen Signed-off-by: Michael Kubacki Reviewed-by: Liming Gao Reviewed-by: Michael D Kinney --- BaseTools/Scripts/PatchCheck.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/BaseTools/Scripts/PatchCheck.py b/BaseTools/Scripts/PatchChe= ck.py index 475b3a8c27d9..a02fdb470ee2 100755 --- a/BaseTools/Scripts/PatchCheck.py +++ b/BaseTools/Scripts/PatchCheck.py @@ -384,7 +384,9 @@ class GitDiffCheck: self.force_crlf =3D False self.force_notabs =3D False if os.path.basename(self.filename) =3D=3D 'GNUmakefile' = or \ - os.path.basename(self.filename) =3D=3D 'Makefile': + os.path.basename(self.filename) =3D=3D 'Makefile' or = \ + self.filename.startswith( + 'BaseTools/Source/C/VfrCompile/Pccts/'): self.force_notabs =3D False elif len(line.rstrip()) !=3D 0: self.format_error("didn't find diff command") --=20 2.28.0.windows.1