Commit Gate
A minimal commit validation tool validating the commit messages of a branch.
Installation
The binary can be installed using the go install command:
$ go install github.com/prichrd/commit-gate
Usage
$ commit-gate -h
Usage of commit-gate:
-path string
path of the git repository (default "./")
-regex string
regular expression matching the expected commit messages (default "^(build|chore|ci|docs|feat|fix|perf|refactor|revert|style|test){1}(\\([\\w-\\.]+\\))?(!)?: ([\\w ])+([\\s\\S]*)")
By default, the CLI uses a regular expression matching Conventional Commits. It can be overriden to whatever you want with the -regex flag.
Docker Image
A Docker image is also available from the Github Package repository:
$ docker run ghcr.io/prichrd/commit-gate:latest -v "$PWD:/src" c --path /src