As of #1520, our NPM workflow automatically publishes to NPM whenever we publish a GitHub release. However, it relies on us manually bumping the package.jsons and it doesn't check whether this has been done. If the package.json versions aren't bumped (particularly the main @finos/git-proxy version), this can override existing releases or mess up subsequent release-drafter.yml executions.
Describe the solution you'd like
We should at least check whether a package.json version bump has occurred, and fail the workflow if so.
Ideally, we would have some script that runs automatically to bump the versions appropriately, perhaps during the release-drafter.yml step which computes the next semantic version. This could create a PR that bumps all the relevant package.jsons (currently ./package.json and ./packages/git-proxy-cli/package.json), which we then review/merge to trigger the actual GitHub release, which will in turn create a valid NPM release.
If we go with the auto-bumping script/workflow, we still need to check before running the NPM workflow in case someone forgot to merge the generated bump PR.
Also, the Releases.md doc should be updated to reflect the improved flow.
Additional context
#1516 (comment)
#1516 (comment)
#1520
As of #1520, our NPM workflow automatically publishes to NPM whenever we publish a GitHub release. However, it relies on us manually bumping the
package.jsons and it doesn't check whether this has been done. If thepackage.jsonversions aren't bumped (particularly the main@finos/git-proxyversion), this can override existing releases or mess up subsequentrelease-drafter.ymlexecutions.Describe the solution you'd like
We should at least check whether a
package.jsonversion bump has occurred, and fail the workflow if so.Ideally, we would have some script that runs automatically to bump the versions appropriately, perhaps during the
release-drafter.ymlstep which computes the next semantic version. This could create a PR that bumps all the relevantpackage.jsons (currently./package.jsonand./packages/git-proxy-cli/package.json), which we then review/merge to trigger the actual GitHub release, which will in turn create a valid NPM release.If we go with the auto-bumping script/workflow, we still need to check before running the NPM workflow in case someone forgot to merge the generated bump PR.
Also, the
Releases.mddoc should be updated to reflect the improved flow.Additional context
#1516 (comment)
#1516 (comment)
#1520