Skip to content
This repository was archived by the owner on Apr 6, 2022. It is now read-only.

Commit e869d25

Browse files
ulfalizergalak
authored andcommitted
check_compliance.py: Run the Nits test on more file types
Check *.conf (e.g. prj.conf), *.dts, *.overlay, *.txt, *defconfig*, and README as well. Signed-off-by: Ulf Magnusson <[email protected]>
1 parent 32a3e07 commit e869d25

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

scripts/check_compliance.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -718,17 +718,20 @@ def run(self):
718718
# Loop through added/modified files
719719
for fname in git("diff", "--name-only", "--diff-filter=d",
720720
COMMIT_RANGE).splitlines():
721-
is_kconfig = "Kconfig" in fname
722-
723-
if is_kconfig:
721+
if "Kconfig" in fname:
724722
self.check_kconfig_header(fname)
725723
self.check_redundant_zephyr_source(fname)
726724

727725
if fname.startswith("dts/bindings/"):
728726
self.check_redundant_document_separator(fname)
729727

730-
if fname.endswith((".c", ".cpp", ".h", ".ld", ".py", ".rst",
731-
".yaml", ".yml")) or is_kconfig:
728+
if fname.endswith((".c", ".conf", ".cpp", ".dts", ".overlay",
729+
".h", ".ld", ".py", ".rst", ".txt", ".yaml",
730+
".yml")) or \
731+
"Kconfig" in fname or \
732+
"defconfig" in fname or \
733+
fname == "README":
734+
732735
self.check_source_file(fname)
733736

734737
def check_kconfig_header(self, fname):

0 commit comments

Comments
 (0)