Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1655678 > unrolled thread
| Started by | Joe Perches <joe@perches.com> |
|---|---|
| First post | 2017-06-01 21:10 +0200 |
| Last post | 2017-06-01 21:10 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 2/2] checkpatch: Warn when a MAINTAINERS entry isn't [A-Z]:\t Joe Perches <joe@perches.com> - 2017-06-01 21:10 +0200
| From | Joe Perches <joe@perches.com> |
|---|---|
| Date | 2017-06-01 21:10 +0200 |
| Subject | [PATCH 2/2] checkpatch: Warn when a MAINTAINERS entry isn't [A-Z]:\t |
| Message-ID | <tNDDP-6I5-1@gated-at.bofh.it> |
For consistency, MAINTAINERS entries should be an upper case letter,
then a colon, then a tab, then the value.
Warn when an entry doesn't have this form. --fix it too.
Signed-off-by: Joe Perches <joe@perches.com>
---
scripts/checkpatch.pl | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index b86ff852b241..7fcaf5ca997b 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -2776,6 +2776,17 @@ sub process {
#print "is_start<$is_start> is_end<$is_end> length<$length>\n";
}
+# check for MAINTAINERS entries that don't have the right form
+ if ($realfile =~ /^MAINTAINERS$/ &&
+ $rawline =~ /^\+[A-Z]:/ &&
+ $rawline !~ /^\+[A-Z]:\t\S/) {
+ if (WARN("MAINTAINERS_STYLE",
+ "MAINTAINERS entries use one tab after TYPE:\n" . $herecurr) &&
+ $fix) {
+ $fixed[$fixlinenr] =~ s/^(\+[A-Z]):\s*/$1:\t/;
+ }
+ }
+
# discourage the use of boolean for type definition attributes of Kconfig options
if ($realfile =~ /Kconfig/ &&
$line =~ /^\+\s*\bboolean\b/) {
--
2.10.0.rc2.1.g053435c
Back to top | Article view | linux.kernel
csiph-web