release-please-action
release-please-action copied to clipboard
The bump-minor-pre-major option in the workflow file is ignored
After trying out the action with the following file
name: Release
on:
push:
branches: [main]
jobs:
release-please:
runs-on: ubuntu-latest
steps:
- uses: GoogleCloudPlatform/release-please-action@v2
id: release
with:
token: ${{ secrets.RELEASE_PLEASE_TOKEN }}
release-type: node
package-name: npm-test-package
bump-minor-pre-major: true
I noticed that every single release starts with v1.0.0 ignoring the bump-minor-pre-major flag. I expected it to start at v0.1.0 as stated in my package.json.
@ChristianIvicevic the problem is that Node.js defaults to v1.0.0 if no prior release can be found.
If you create a release pointing to your main branch, with the tag v0.1.0, it will do the right thing.
As a more permanent fix, I was thinking that we should figure out how to make Node.js releases default to the value in the package.json.
Oh I see - it'd be awesome if that behavior is documented in the readme. Unfortunately I had to start my package at v1.0.0 for the time being. Thanks for the explanation.
At least it hasn't been 72h yet so I can unpublish my package and restart at v0.1.0.
This makes the OOBE for a basic, unreleased JS project not so great. I'm still struggling with token errors, but I see in the logs that it wants to start with v1.0.0, when it's at 0.0.1 in the package.json. Tagging a fake release at v0.0.1 doesn't feel right, but maybe that'll work.