amannn / action-semantic-pull-request

A GitHub Action that ensures that your PR title matches the Conventional Commits spec
MIT License
984 stars 124 forks source link

Allow declarative commit type configuration #12

Closed abatilo closed 4 years ago

abatilo commented 4 years ago

Projects like the GitHub App zeke/semantic-pull-request allow for configuration which lets you control things like the list of commit types that are allowed.

amannn commented 4 years ago

That's true. Currently I'm using the list of conventional commit types to validate the PR title:

https://github.com/amannn/action-semantic-pull-request/blob/78559164c6e2034786e28fb92135d2f6c000a418/src/validatePrTitle.js#L16

Would you be interested in contributing the configurability you need with a PR?

abatilo commented 4 years ago

In principle, totally, but practically, I don't know a thing about writing any real JavaScript 😅 . If there were already some kind of config file class/module, I could try to extend it.

amannn commented 4 years ago

Oh ok, no worries 😄. What kind of commit prefixes are you looking for that are currently not supported?

abatilo commented 4 years ago

For me, it's about the fact that the list is based on some other repository that I don't control. If they changed the list, I might start getting really confused.

amannn commented 4 years ago

I think we should be able to handle that with semver. If they remove types from the package, that should be a breaking change. This library also respects semver, so you shouldn't have to worry about any breaking changes within non-major releases. In any cases I'd pin the version of action-semantic-pull-request you're using.

Does that make sense to you?

abatilo commented 4 years ago

It does. That makes a lot of sense. Thank you! Let's close this.