Steps to take when releasing new module versions.
Check out the main
branch and git pull
so you have the latest.
To bump all packages:
npm version patch --workspace=packages # Or minor, major, etc.
To bump certain packages:
cd packages/core # Or some other package
npm version patch # Or minor, major, etc.
Stage and commit the changes:
git add .
git commit -m "chore: Release 0.4.0" # Swap with target version
To dry run a publish of all packages:
npm publish --dry-run --workspace=packages
To dry run a publish of certain packages (e.g. core
):
cd packages/core # Or some other package
npm publish --dry-run
This should build the relevant packages and show log output of what package versions would have been published. Check it is correct.
Use the same commands as the publish dry run without the --dry-run
argument.
Verify packages were published successfully, check npmjs.com and/or run:
npm view [PACKAGE]
Once verified, push the version bump changes commit to remote:
git push
If core
was bumped, create a new tag and push it:
# Swap with target versions
git tag @prpl/[email protected]
git push origin @prpl/[email protected]
Tags should not be created for other packages.
Update the changelogs with relevant information for each updated package.
This process is manual for the time being since the project no longer uses Lerna.
Update docs and example sites with the new published versions.
This process is manual for the time being, try npm update --workspaces=1 and see if it works.
For substantial changes, create a GitHub release from the new tag in GitHub. List what the release contains in the description with links to PRs.
That's it!
This project used to have more automation, but has removed Lerna since it's no longer maintained and does way more than what this project requires.
Over time I'd like to automate changelog updates again but without any third party dependencies. If you're interested in helping out, please feel free to open a PR!