Branch is setup to *not* be a prerelease, yet the release is flagged as 'pre-release'.
See original GitHub issue{
"branches": [
{
"name": "main",
"prerelease": false
},
{
"name": "development",
"prerelease": true
},
{
"name": "staging",
"prerelease": false
}
],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/github"
]
}
This config does not throw an error, but behaves inconsistent. Pushing to staging
does not create a release, but a pre-release.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:6
Top Results From Across the Web
`next` - Intuit
Calling the next command from a prerelease branch will publish a prerelease for just that branch, otherwise it will publish to the default...
Read more >@lerna/version - npm
Running lerna version --conventional-commits without the above flags will release current changes as prerelease only if the version is already in prerelease ......
Read more >Adobe Experience Manager as a Cloud Service Prerelease ...
Each release is accompanied by release notes that document not only what is new in that release, but also the features that are...
Read more >Semantic Versioning 2.0.0 | Semantic Versioning
Additional labels for pre-release and build metadata are available as extensions to the MAJOR.MINOR.PATCH format. Introduction. In the world of software ...
Read more >Create release - Octopus Deploy
--packagePrerelease=VALUE [Optional] Pre-release for latest version of ... Flag] Perform a dry run but don't actually create/deploy release.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Same here. 😢
It may be due to this check: https://github.com/semantic-release/github/blob/master/lib/is-prerelease.js#L1. It tags as pre-release any branch marked as pre-release, or any branch marked as release and not tagged as
main
. As per https://github.com/semantic-release/semantic-release/blob/971a5e0d16f1a32e117e9ce382a1618c8256d0d9/lib/branches/normalize.js#L87, it looks like there can be only onemain
tagged branch, thus, only one branch not beeing used as pre-release (in the case of the GitHub plugin). I was not able to find references with multiplemain
branches, see https://github.com/semantic-release/semantic-release/blob/971a5e0d16f1a32e117e9ce382a1618c8256d0d9/test/branches/normalize.test.js#L150.This issue was introduced with https://github.com/semantic-release/github/pull/235.
Possible workaround
In my case I’m defining two branches objects:
Moving the master branch first should prevent pre-releases from being created for this branch.