Skip to content

Commit

Permalink
Merge pull request #804 from OneCommunityGlobal/diego_add_conventiona…
Browse files Browse the repository at this point in the history
…l_commits_git_hook

Diego add conventional commits with husky
  • Loading branch information
one-community authored Mar 22, 2024
2 parents 7292e3d + 0839328 commit 4741528
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/sh
if ! head -1 "$1" | grep -qE "^(feat|fix|chore|docs|test|style|refactor|perf|build|ci|revert)!?(\(.+?\))?: .{1,}$"; then
echo "Aborting commit. Your commit message is invalid." >&2
exit 1
fi
if ! head -1 "$1" | grep -qE "^.{1,120}$"; then
echo "Aborting commit. Your commit message is too long." >&2
exit 1
fi
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 4741528

Please sign in to comment.