Commits

Anonymous committed e77235e

Fix regex pattern in commit-msg

Between the count and the line output, some
uniq(1) versions put a TAB character, not a space.
Make sure both are handled.

Signed-off-by: Luben Tuikov <ltuikov@yahoo.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>

  • Participants
  • Parent commits 01aaf1f

Comments (0)

Files changed (1)

File templates/hooks--commit-msg

 # This example catches duplicate Signed-off-by lines.
 
 test "" = "$(grep '^Signed-off-by: ' "$1" |
-	 sort | uniq -c | sed -e '/^[ 	]*1 /d')"
+	 sort | uniq -c | sed -e '/^[ 	]*1[ 	]/d')"