1.0.0 • Published 2 years ago

@alexwei/commit-lint v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

commit-lint

Lint commit messages using Angular's commit convention


What is commit-lint

commit-lint is not the same as commitlint. It's extremely simple, doesn't support rule configuration, and enforces Angular's commit conventions. It was born inspired by Vue related projects.

Usage

Install

npm i @alexwei/commit-lint -D

Add Hook

With husky, add command to .husky/commit-msg file.

#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx commit-lint $1

With simple-git-hooks, add command to package.json file.

"simple-git-hooks": {
    "commit-msg": "npx commit-lint $1"
}

With yorkie, add command to package.json file.

"gitHooks": {
    "commit-msg": "npx commit-lint $1"
}

License

MIT