-
Notifications
You must be signed in to change notification settings - Fork 926
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
fix: commitlint --extends is ignored for commitlint/config-conventional (v18.6.1) #3909
Comments
I could narrow this down: The problem is caused by the @commitlint/config-conventional@18.6.1 package if I dowgrade this to @commitlint/config-conventional@18.6.0 everything works again. |
Looks like the refactoring to typescript caused the problem: 345bcf5 In js the ruleset was defined in |
The PR creator was informed. Happy for anyone else who wants to fix this. |
Something like this? #3911 |
I've always used a {
"extends": ["@commitlint/config-conventional"]
} Executing #!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"
pnpm commitlint --edit $1 On But on ✖ Please add rules to your `commitlint.config.js`
- Getting started guide: https://commitlint.js.org/#/?id=getting-started
- Example config: https://github.com/conventional-changelog/commitlint/blob/master/%40commitlint/config-conventional/src/index.ts [empty-rules]
✖ found 1 problems, 0 warnings
ⓘ Get help: https://github.com/conventional-changelog/commitlint/#what-is-commitlint Running it from the CLI produces the same error. echo "chore: bump deps" | pnpm commitlint
✖ Please add rules to your `commitlint.config.js`
- Getting started guide: https://commitlint.js.org/#/?id=getting-started
- Example config: https://github.com/conventional-changelog/commitlint/blob/master/%40commitlint/config-conventional/src/index.ts [empty-rules]
✖ found 1 problems, 0 warnings
ⓘ Get help: https://github.com/conventional-changelog/commitlint/#what-is-commitlint Re-added this as realised it only relates to |
This comment was marked as off-topic.
This comment was marked as off-topic.
It looks like this broke my CI as well. $ npm install --global @commitlint/config-conventional @commitlint/cli
added 199 packages in 8s
31 packages are looking for funding
run `npm fund` for details
$ npm --version
10.2.4
$ export COMMITS_IN_BRANCH=$(git rev-list $CI_MERGE_REQUEST_DIFF_BASE_SHA..$CI_COMMIT_SHA | wc --lines)
$ export BACKREFERENCE_COUNT=$(($COMMITS_IN_BRANCH - 1))
$ npx commitlint --verbose --from HEAD~$BACKREFERENCE_COUNT
✖ Please add rules to your `commitlint.config.js`
- Getting started guide: https://commitlint.js.org/#/?id=getting-started
- Example config: https://github.com/conventional-changelog/commitlint/blob/master/%40commitlint/config-conventional/src/index.ts [empty-rules]
✖ found 1 problems, 0 warnings
ⓘ Get help: https://github.com/conventional-changelog/commitlint/#what-is-commitlint
Cleaning up project directory and file based variables 00:00
ERROR: Job failed: exit code 1 I have a .commitlintrc.yml at the root of the repository that it normally picks up fine. |
Please give this a try: Thanks to @dargmuesli for jumping in and @masterT, @jerome-benoit and @knocte for review and feedback! |
So far, so good on all the ESM repos I use that was broken by the previous release. Thanks. |
18.6.2 works for me, thank you! |
Same here, it's working with 18.6.2, thanks! 🙂 |
+1 |
Expected Behavior
Commits shall be linted.
Current Behavior
Error: Please add rules to your
commitlint.config.js
Affected packages
Possible Solution
No response
Steps to Reproduce
Context
The steps to reproduce worked in the last version (18.6.0)
commitlint --version
@commitlint/cli@18.6.1
git --version
2.39.2
node --version
10.2.3
The text was updated successfully, but these errors were encountered: