Skip to contentSkip to conversation

checkpatch: check SPDX tags in YAML files

PATCH Applied Lubomir Rintel 2 participants 2 messages Jan 29, 2020 – Jan 30, 2020 Checkpatch

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 checkpatch: check SPDX tags in YAML files

This adds a warning when a YAML file is lacking a SPDX header on first line, or it uses incorrect commenting style.

Currently the only YAML files in three are Devicetree binding documents.

---
 scripts/checkpatch.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/checkpatch.pl +1 -1
index a63380c6b0d20..e2976c3fe5ff8 100755
@@ -3087,7 +3087,7 @@ sub process {
 					$comment = '/*';
 				} elsif ($realfile =~ /\.(c|dts|dtsi)$/) {
 					$comment = '//';
-				} elsif (($checklicenseline == 2) || $realfile =~ /\.(sh|pl|py|awk|tc)$/) {
+				} elsif (($checklicenseline == 2) || $realfile =~ /\.(sh|pl|py|awk|tc|yaml)$/) {
 					$comment = '#';
 				} elsif ($realfile =~ /\.rst$/) {
 					$comment = '..';
Signature · 1 line
2.24.1
maintainer
#1 lore raw
Quoted 4 lines · Lubomir Rintel

This adds a warning when a YAML file is lacking a SPDX header on first line, or it uses incorrect commenting style.

Currently the only YAML files in three are Devicetree binding documents.

three/tree typo?

Otherwise, looks fine.