Commit 0dc0c93a authored by Auke L. Klazema's avatar Auke L. Klazema

SW-773: Fix commit-msg hook for real

parent 56e189f4
......@@ -4,7 +4,7 @@ message_file = ARGV[0]
message = File.read(message_file)
$regex = /^((fixes|task|story|issue)\s)?(#(\d+)|[a-zA-Z]+-(\d)+):/i
if !$regex.match(message)
STDERR.puts("[commit-msg hook] Your commit #{ rev } was rejected!\n"\
STDERR.puts("[commit-msg hook] Your commit was rejected!\n"\
"[commit-msg hook] A commit message must start with a JIRA task ID,\n"\
" or \"task\", \"story\", \"issue\" or \"fixes\", followed by an issue ID.\n"\
"[commit-msg hook] For example: \"Task #42: Fixed bug\" or \"SW-22334: Fixed bug\"\n"\
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment