-
Notifications
You must be signed in to change notification settings - Fork 7
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
feat(config): CHP-7101 add commitlint-config-jira #54
Conversation
// https://github.com/conventional-changelog/commitlint/issues/2631 | ||
// eslint-disable-next-line @typescript-eslint/ban-ts-comment | ||
// @ts-expect-error | ||
'subject-case': [2, 'never', ['start-case', 'pascal-case']], |
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.
I submitted a PR in commitlint
to resolve this issue. Waiting for that to get merged.
|
||
const RELEASE_REGEX = new RegExp('Releas(e|ing) v?\\d+\\.\\d+\\.\\d+'); | ||
|
||
export const releases: Matcher = (commit: string) => RELEASE_REGEX.test(commit); |
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.
By default commitlint
ignores validation on semver commits, but validates commits with prefixes.
Also, I caught that this test case will be valid now since they check for semver commits. IMO it's not a big deal for this one case, and it's not a breaking change, so I'm fine allowing it. If we need to still cover that, I'll try and think of a way.
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.
Other than the typo, the rest looks good.
|
||
const RELEASE_REGEX = new RegExp('Releas(e|ing) v?\\d+\\.\\d+\\.\\d+'); | ||
|
||
export const releases: Matcher = (commit: string) => RELEASE_REGEX.test(commit); |
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.
🍹 Do we want to add some tests for this, to make sure it does what it should do?
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.
Let me throw up another PR for this, since it'll include adding jest to package.
What/why?
Adds the "recommended" config that we (BigCommerce) adhere to.