lendis-git-hooks v1.0.4
Description
Git hooks are scripts that run automatically every time a particular event occurs in a Git repository. They can be used to enforce version control best practices.
Setup
Install with npm:
npm i lendis-git-hooks
enable them by running:
npx hooks --init
Existing hooks
- commit-msg
A Git hook automatically invoked by git commit
.
Utilizes regex to check if the commit message follows a specific structure. Failing to successfully pass the validation it will result to not allow the user to commit the code.
Current pattern
<IU-ticketnumber>: <context-name>
Example: IU-123: commit message
- pre-push
A Git hook automatically invoked by git push
.
Utilizes regex to check if the branch name follows a specific structure.
Current pattern
<IU-ticketnumber>_<context-name>
Example: IU-345_example-message
How to contribute
This repository adheres to Semantic Versioning once it hits v1.0.0. If you change anything, make sure to add you changes to the CHANGELOG.md.