]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
scripts: git commit message hook: prohibit use of "Signed-off-by:"
authorJim Meyering <meyering@redhat.com>
Thu, 30 Aug 2012 11:07:10 +0000 (13:07 +0200)
committerJim Meyering <meyering@redhat.com>
Thu, 30 Aug 2012 11:12:44 +0000 (13:12 +0200)
* scripts/git-hooks/commit-msg: Reject a commit log message that
contains "Signed-off-by:".

scripts/git-hooks/commit-msg

index a5e409071cbe0e845ab7ac538e4499cc715c0c6c..f867331d2c8cd1894b51b5ab99f5b532aa1053a1 100755 (executable)
@@ -125,6 +125,9 @@ sub check_msg($$)
   $buf =~ m!https?://debbugs\.gnu\.org/(?:cgi/bugreport\.cgi\?bug=)?(\d+)!s
     and return "use shorter http://bugs.gnu.org/$1";
 
+  $buf =~ /^ *Signed-off-by:/i
+    and return q(do not use "Signed-off-by:");
+
   return '';
 }