-
Notifications
You must be signed in to change notification settings - Fork 220
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Commitlint #110
Comments
Try it like usual executable you have: commit-msg:
commands:
commitlint:
run: echo "wololo" | commitlint Or try it just like script: |
Thank you! I'll try and update this issue with new information. |
I modify your script with type-enum from https://github.com/conventional-changelog/commitlint/tree/master/%40commitlint/config-conventional#type-enum Looks like: INPUT_FILE=$1
START_LINE=`head -n1 $INPUT_FILE`
PATTERN="^(build|ci|docs|feat|fix|perf|refactor|revert|style|test)+: "
if ! [[ "$START_LINE" =~ $PATTERN ]]; then
echo -e "Invalid commit message.\nCommit message must start with '(build|ci|docs|feat|fix|perf|refactor|revert|style|test):'"
exit 1
fi Thank you for help! |
Hi!
I want to use Lefthook with Commitlint on pre-commit.
In Commitlint's docs I found
"commit-msg": "commitlint -E HUSKY_GIT_PARAMS"
(https://github.com/conventional-changelog/commitlint#getting-started). But Lefthook hasn'tHUSKY_GIT_PARAMS
of course :)What should I do to solve this problem?
The text was updated successfully, but these errors were encountered: