-
Notifications
You must be signed in to change notification settings - Fork 2
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
[Feature] Add commit linting #10
Conversation
force adhering to the conventional commit guidelines by automatically lint commit messages for compliance. this is done on a commit hook via the commitlint and husky packages.
All automatic local checking is enabled with this PR. Next step would be to enable remote linting via Travis CI, so squashed commits that are created on GitHub while merging can be checked, too. |
- move config from `package.json` to external config `.huskyrc`
- change list to comply with angular guidelines - add allowed types to contribution guidelines
6913453
to
3e9cd6d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All automatic local checking is enabled with this PR. Next step would be to enable remote linting via Travis CI, so squashed commits that are created on GitHub while merging can be checked, too.
This also prevents bypassing the commit-guidelines by using --no-verify
.
This requires setup on Travis CI for this repo
- Setup Travis CI
- Setup commitlint on Travis
Setting up Travis CI isn’t the hard part. I tested it in a demo repository. What Travis CI can’t do however, is run a command after the PR is merged. That means when merging the PR with a squashed commit, the feature is merged and Travis CI can’t check against that anymore. I suggest to discuss this separately, as I think this needs to be considered alongside a Git release branching strategy. |
I think we should discuss this in person when we see each other again (see https://github.com/csshugs/FluidMS/projects/1#card-27096650). Can this be merged then? |
Force adhering to the conventional commit guidelines by automatically
lint commit messages for compliance. This is done on a commit hook
via the
commitlint
andhusky
packages.See issue #9
Closes #9