semantic-release / semantic-release/commit-analyzer
Prevent semantic release from being triggered by certain default prefixes
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 448
- Forks
- 82
- Avg merge
- 17h 41m
- Merged PRs (30d)
- 4
Description
Hi everyone! I'm currently using Semantic Release in my project and I'd like to configure it so that it doesn't trigger a release for commits labeled as fix or feat. However, I couldn't find a straightforward way to achieve this in the existing configuration options.
I propose adding a feature or configuration option that allows users to exclude specific commit types, by setting a certain prefix to false. I found an example for scopes.
Here is an example of my package.json file:
{
"name": "semantic-release-image",
"release": {
"branches": ["main"],
"plugins": [
[
"@semantic-release/commit-analyzer",
{
"releaseRules": [
{
"type": "feat",
"release": "prerelease"
},
{
"type": "feat",
"scope": "release",
"release": "minor"
},
{
"type": "perf",
"release": "prerelease"
},
{
"type": "BREAKING CHANGE",
"release": "major"
},
{
"type": "revert",
"release": "prerelease"
},
{
"type": "fix",
"release": "prerelease"
}
],
"parserOpts": {
"noteKeywords": ["BREAKING CHANGE", "BREAKING CHANGES"]
}
}
]
[
"@semantic-release/github"
]
]
}
}
As you can see, now I set those default prefixes to prerelease and that's not what I am aiming for.
If this feature exists, please, let me know how to achieve it.
Thanks in advance!
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the @semantic-release/commit-analyzer configuration shown in package.json and the linked releaseRules scope example in the README. Determine how commit types such as fix and feat are currently handled, then define the configuration behavior and verification needed for excluding them without assigning a release.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- release, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100