diff options
author | Tom Willemse | 2014-04-12 14:37:27 +0200 |
---|---|---|
committer | Tom Willemse | 2014-04-12 14:37:27 +0200 |
commit | 0a570ca8318750f02039cfefb2d3a16d96457522 (patch) | |
tree | a81eea4f8c8793b0573de80b527d21927a31cd33 | |
parent | 135c366f6223ecec4f7980ef3cf82c265db2b041 (diff) | |
download | commit-check-0a570ca8318750f02039cfefb2d3a16d96457522.tar.gz commit-check-0a570ca8318750f02039cfefb2d3a16d96457522.zip |
Improve error messages
-rwxr-xr-x | commit-check | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/commit-check b/commit-check index ae80804..cc3a9b8 100755 --- a/commit-check +++ b/commit-check @@ -124,13 +124,13 @@ while (<$commitfile>) { $lineno++; # Start at 1, so increment first if ($lineno == 1) { - err "Not capitalized" if /^[^[:upper:]]/; - err "Longer than 50 characters" if /^.{51,}/; + err "First line is not capitalized" if /^[^[:upper:]]/; + err "First line is longer than 50 characters" if /^.{51,}/; next; } - err "Should be empty" if $lineno == 2 && /.+/; - err "Longer than 72 characters" if /^.{73,}/; + err "Second line should be empty" if $lineno == 2 && /.+/; + err "Line is longer than 72 characters" if /^.{73,}/; } close $commitfile; |