From: Parav Pandit <parav@mellanox.com>
To: joe@perches.com, apw@canonical.com
Cc: linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org,
parav@mellanox.com, Brad Erickson <bradley@mellanox.com>
Subject: [PATCH] checkpatch: Introduce check for format of Fixes line in commit log
Date: Tue, 10 Oct 2017 17:44:27 -0500 [thread overview]
Message-ID: <1507675467-24316-1-git-send-email-parav@mellanox.com> (raw)
This patch introduces a format check for 'Fixes' line in commit log
for 12 characters commit id and format for Fixes as ("...").
Its created against linux-rdma Doug's tree [1].
[1] git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma.git
Signed-off-by: Parav Pandit <parav@mellanox.com>
Signed-off-by: Brad Erickson <bradley@mellanox.com>
---
scripts/checkpatch.pl | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index dd2c262..7d933e4 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -2548,6 +2548,14 @@ sub process {
"Remove Gerrit Change-Id's before submitting upstream.\n" . $herecurr);
}
+# Check for incorrect format for Fixes line in commit log
+ if ($in_commit_log && $line =~ /^\s*Fixes:/i) {
+ if ($line !~ /^\s*Fixes: [a-z0-9]{12} \(\".*?\"\)$/i) {
+ ERROR("FIXES_FORMAT",
+ "Follow format of Fixes: <12 characters commit id> (\"...\")\n" . $herecurr);
+ }
+ }
+
# Check if the commit log is in a possible stack dump
if ($in_commit_log && !$commit_log_possible_stack_dump &&
($line =~ /^\s*(?:WARNING:|BUG:)/ ||
--
1.8.3.1
next reply other threads:[~2017-10-10 22:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-10 22:44 Parav Pandit [this message]
2017-10-19 5:52 ` Parav Pandit
2017-10-19 5:57 ` Joe Perches
2017-10-19 6:11 ` Parav Pandit
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1507675467-24316-1-git-send-email-parav@mellanox.com \
--to=parav@mellanox.com \
--cc=apw@canonical.com \
--cc=bradley@mellanox.com \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®