summaryrefslogtreecommitdiffstats
path: root/git-hooks
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2011-05-23 20:20:11 +0200
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2011-05-23 20:22:15 +0200
commit42ec0a6f029e15043dab126f13a8cb6be30b71b3 (patch)
treefd56fd70f6a42505a026f066ede216ba6d599c68 /git-hooks
parentd29f1f15b355b4c0423241f69a135141746e9423 (diff)
make the log message summary hint not lower the score
Diffstat (limited to 'git-hooks')
-rwxr-xr-xgit-hooks/sanitize-commit4
1 files changed, 2 insertions, 2 deletions
diff --git a/git-hooks/sanitize-commit b/git-hooks/sanitize-commit
index ef3e5ed..dd0b679 100755
--- a/git-hooks/sanitize-commit
+++ b/git-hooks/sanitize-commit
@@ -61,7 +61,7 @@ sub complain()
}
$pfx = $lpfx."- ";
}
- $level = 0 if (!defined($level) || ($level < 0 && $strict));
+ $level = 0 if (!defined($level) || ($level < 0 && $strict && length($key)));
if ($level >= 0) {
$fail = $level + 1 if ($level >= $fail);
if ($gerrit) {
@@ -93,7 +93,7 @@ while (<MSG>) {
&complain("Log message summary is excessively long", "log");
$badlog = 1;
} elsif (length($_) > 70 && !/^Merge ((remote )?branch '[^ ]+'|branch '[^ ]+' of [^ ]+( into [^ ]+)?)$/) {
- &complain("Hint: Aim for shorter log message summaries", "");
+ &complain("Aim for shorter log message summaries", "", -1);
}
} elsif ($ln == 1) {
if (!$badlog && $_ ne "") {