path: root/scripts
diff options
authorChristopher Covington <>2014-04-03 14:49:31 -0700
committerLinus Torvalds <>2014-04-03 16:21:15 -0700
commit7ebd05ef1646e8cbef54e38343722741a4744626 (patch)
tree1d00e5ffc3bd7d989a573b0dc9d92dbc9c71c686 /scripts
parent74915c7dd0e144cc735058a77a3901c98f1e7039 (diff)
downloadlinux-7ebd05ef1646e8cbef54e38343722741a4744626.tar.gz add check for Change-Id
A commit hook for the Gerrit code review server [1] inserts change identifiers so Gerrit can track patches through multiple revisions. These identifiers are noise in the context of the upstream kernel. (Many Gerrit servers are private. Even given a public instance, given only a Change-Id, one must guess which server a change was tracked on. Patches submitted to the Linux kernel mailing lists should be able to stand on their own. If it's truly useful to reference code review on a Gerrit server, a URL is a much clearer way to do so.) Thus, issue an error when a Change-Id line is encountered before the Signed-off-by. 1. Signed-off-by: Christopher Covington <> Cc: Joe Perches <> Cc: Andy Whitcroft <> Signed-off-by: Andrew Morton <> Signed-off-by: Linus Torvalds <>
Diffstat (limited to 'scripts')
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/ b/scripts/
index d9b09eb767bb..fbb1b7e88e87 100755
--- a/scripts/
+++ b/scripts/
@@ -1924,6 +1924,12 @@ sub process {
+# Check for unwanted Gerrit info
+ if ($in_commit_log && $line =~ /^\s*change-id:/i) {
+ "Remove Gerrit Change-Id's before submitting upstream.\n" . $herecurr);
+ }
# Check for wrappage within a valid hunk of the file
if ($realcnt != 0 && $line !~ m{^(?:\+|-| |\\ No newline|$)}) {