Skip to content
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

Merged
merged 3 commits into from
Oct 1, 2019
Merged

[Feature] Add commit linting #10

merged 3 commits into from
Oct 1, 2019

Conversation

csshugs
Copy link
Owner

@csshugs csshugs commented Sep 27, 2019

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.

See issue #9

Closes #9

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.
@csshugs csshugs added the feature New feature label Sep 27, 2019
@csshugs csshugs requested a review from fuhlig September 27, 2019 06:00
@csshugs
Copy link
Owner Author

csshugs commented Sep 27, 2019

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
Copy link
Collaborator

@fuhlig fuhlig left a 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

commitlint.config.js Show resolved Hide resolved
commitlint.config.js Show resolved Hide resolved
@fuhlig fuhlig self-requested a review September 27, 2019 16:13
@fuhlig fuhlig assigned csshugs and unassigned fuhlig Sep 27, 2019
@csshugs
Copy link
Owner Author

csshugs commented Sep 30, 2019

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.

@csshugs
Copy link
Owner Author

csshugs commented Oct 1, 2019

@fuhlig

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?

@csshugs csshugs assigned fuhlig and unassigned csshugs Oct 1, 2019
@fuhlig fuhlig merged commit 7c6a20a into develop Oct 1, 2019
@fuhlig fuhlig deleted the feature/9/commit-linting branch October 2, 2019 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants