chore: improve bump versions script #971
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Set as Draft PR if it's not ready to be merged.
PR best practices Reference
Description
Automate even more package dependency updates for templates and botonic packages with deps to other botonic packages to speed up the process and minimize potential errors.
Usage
For example, for the next release we can do:
For preparing rc versions, we can run the bash script:
$ ./bump-version.sh 0.15.0-rc.0 rc
will leave the dependencies for templates, react and plugin-nlu in the following format:
./botonic-react/package.json
"@botonic/core": "0.15.0-rc.0"
For definitive versions, we can run the bash script:
$ ./bump-version.sh 0.15.0
will leave the dependencies for templates, react and plugin-nlu in the following format:
./botonic-react/package.json
"@botonic/core": "~0.15.0"
Context
Right now we were calling
npm version $VERSION
which updated both package.json and package-lock.json for every dependency, but we still need to manually replace the versions for all templates and botonic packages which have another botonic package as a dependency (botonic-plugin-nlu and botonic-react).@dpinol maybe you have suggestions to improve this even more