We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cc4506c commit 106a1c3Copy full SHA for 106a1c3
.githooks/commit-msg
@@ -0,0 +1,11 @@
1
+#!/usr/bin/env ruby
2
+
3
+message_file = ARGV[0]
4
+message = File.read(message_file)
5
6
+$grammar_regex = Regexp.new('^:(memo|art|racehorse|non-potable_water|bug|fire|green_heart|white_check_mark|lock|arrow_up|arrow_down|shirt):\s[A-Z][\w\d\s]*[\w\d]\.(\s(Related to)[#\w\d\s]*[\w\d]\.)?$')
7
8
+if !$grammar_regex.match(message)
9
+ puts "Your message does not match with the rules defined in the CONTRIBUTING.md."
10
+ exit 1
11
+end
0 commit comments