Steps for a new release (these are in the process of being automated):
-
Check out
mainand make sure you have pulled down the latest changes (git pull origin main --tags) -
Run
yarn releasewhich usesstandard-versionto:- Determine the new version based on new commit messages
- Generate a new entry in the changelog with the version, release notes, and today's date.
- Commit all of the above changes with the message
chore(release): <version> - Note: Creating a new tag is skipped (this will happen as part of the publish flow)
-
Push changes to a new branch following the naming pattern:
release-<version>- For example:
git checkout -b release-1.1.0
- For example:
-
Open a PR for the release branch against
main, with the changelog generated by the previous step included in the PR description.- PR title should be
chore(release): <version> - Ask for approvals from stakeholders, perform testing on applications, etc.
- Last minute bugfix from testing or PR feedback can be made.
- Add bugfix commits on top of the release. Squash and merge the PR as usual.
- For significant bugfix (special case)
- Redo the release. Reset your local release branch, add bugfix commits (use conventional commits syntax). Rerun
yarn release. The release chore commit should be the last commit on the branch. The fix will be included in the changelog. _Rebase and merge the PR in this special case.
- Redo the release. Reset your local release branch, add bugfix commits (use conventional commits syntax). Rerun
- PR title should be
-
Once the release PR is approved, complete the release and publish the new version (this should be automated by GH - TODO):
- Merge the PR and create a new release tag pointed at
mainon Github. Use the same notes as release PR. - Pull down latest
mainlocally before publishing -git pull origin main --tags - Publish the new package to npm:
npm publish. You will be prompted for a MFA code.- You may need to
npm loginfirst. - Publishing access is limited to package owners. If you need access and don't have it, please contact
@npm-adminson Truss Slack.
- You may need to
- Merge the PR and create a new release tag pointed at
