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

Only lint merge commits / squash & merge PRs #159

Closed
suzubara opened this issue May 18, 2020 · 2 comments · Fixed by #210
Closed

Only lint merge commits / squash & merge PRs #159

suzubara opened this issue May 18, 2020 · 2 comments · Fixed by #210
Assignees
Labels
type: development Enhancements to the development workflow

Comments

@suzubara
Copy link
Contributor

Right now, commitlint is set up to make sure every commit message follows the conventional commits format. That way, certain types of commits will automatically be included in the changelog. However, we'd like to support a workflow where only merge commits, and/or squash and merge PR titles have to match the format. Ideally a developer can check out a branch, write whatever commits they want, and then when they merge a PR the commit message will match the conventional commits format (probably based off the PR title).

https://github.com/conventional-changelog/standard-version
https://commitlint.js.org/#/

@suzubara suzubara added type: development Enhancements to the development workflow workflow labels May 18, 2020
@suzubara suzubara removed the workflow label May 20, 2020
@suzubara suzubara self-assigned this May 27, 2020
@suzubara
Copy link
Contributor Author

My proposed solution:

  • Add DangerJS config to force PR titles to pass the conventional commit lint spec
  • This repo only enables squash & merge for PRs so that should mean all commits to develop/master will be covered by the DangerJS rule
  • Remove commitlint hook from the commit-level

feedback/ways this won't work is welcome!

@suzubara suzubara added the status: needs requirements This issue is NOT ready for development - it needs further scope clarification or questions answered label May 27, 2020
@suzubara
Copy link
Contributor Author

OTOH why configure dangerJS when a github action exists.. https://github.com/marketplace/actions/semantic-pull-request

@suzubara suzubara removed the status: needs requirements This issue is NOT ready for development - it needs further scope clarification or questions answered label May 28, 2020
suzubara pushed a commit that referenced this issue May 28, 2020
* chore: add semantic pr workflow

* chore: update workflow

* Remove commitlint hook

* Clarify PR linting requirement

Co-authored-by: HANA <hana@truss.works>
suzubara pushed a commit that referenced this issue May 28, 2020
* Bump standard-version from 7.1.0 to 8.0.0

Bumps [standard-version](https://github.com/conventional-changelog/standard-version) from 7.1.0 to 8.0.0.
- [Release notes](https://github.com/conventional-changelog/standard-version/releases)
- [Changelog](https://github.com/conventional-changelog/standard-version/blob/master/CHANGELOG.md)
- [Commits](conventional-changelog/standard-version@v7.1.0...v8.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Created issue templates

Created issue templates for feature request & bug report, with default labels.

* fix: removes the usa-search class name from the form component (#184)

fix #163

* fix: accept id and name props for Search component input field (#183)

* fix: accept id and name props for Search component input field
* fix: qualify id and name props for input field to not clash with form
fix #162

* feat: add dateInput component for forms (#144)

* Added dateInput component and dateInputGroup component for forms

* fix: extends header menu to accept list props for corresponding id (#188)

fix #165

* fix: update gov banner to uswds version 2.7.0

* chore: upgrade uswds to 2.7.0

* docs: add documentation for Trussels (#190)

* docs: add documentation for Trussels

* docs: clean up readme to meet project standards

* docs: add to active maintainers

* docs: add first pass of security policy

Co-authored-by: HANA <hana@truss.works>

* feat: add Footer component #142 (#146)

- adds slim, medium, and big footers with mobile styles
- adds new components, specifically Address, Footer,  FooterNav, FooterExtendedNavList, Logo, SocialLinks

* build(deps-dev): bump @testing-library/jest-dom from 5.7.0 to 5.8.0 (#197)

* build(deps-dev): bump typescript from 3.9.2 to 3.9.3 (#196)

* build(deps-dev): bump @storybook/react from 5.3.18 to 5.3.19 (#198)

* build(deps-dev): bump stylelint from 13.4.1 to 13.5.0 (#199)

* build(deps-dev): bump lint-staged from 10.2.4 to 10.2.6 (#200)

* build(deps-dev): bump @storybook/addon-info from 5.3.18 to 5.3.19 (#201)

* feat(rangeinput): creates form RangeInput component, test, and stories (#194)

* feat(rangeinput): creates form RangeInput component, test, and stories

* feat: add RangeInput component to index.ts for entrypoint export

* feat: remove overalpping interface props with HTMLInputAttributes type

* feat: require id and name props, remove label, remove redundant unpack

* feat: remove unused label import in component, show label usage in story

fixes #81

* docs: add landing page and documentation page template stories (#195)

* docs: add landing page and documentation page template stories

* docs(storybook): add current class to header navigation

* ci: lint PR titles instead of commits #159 (#210)

* chore: add semantic pr workflow

* chore: update workflow

* Remove commitlint hook

* Clarify PR linting requirement

Co-authored-by: HANA <hana@truss.works>

* chore(release): 1.4.0

* Remove duplicate entry from changelog

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Duncan <52669884+duncan-truss@users.noreply.github.com>
Co-authored-by: Emily Mahanna <56279459+eamahanna@users.noreply.github.com>
Co-authored-by: HANA <hana@truss.works>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: development Enhancements to the development workflow
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant