We use Changesets for versioning and GitHub Actions for publishing. The process is as follows:
-
After making changes, create a changeset locally:
yarn changeset
-
Follow the prompts to describe your changes and select the appropriate version bump.
-
Commit the generated changeset file along with your code changes.
-
Push your changes and open a pull request:
git push
-
The pull request should contain your code changes and the new changeset file(s).
-
Once the pull request is merged to the main branch, the CI/CD pipeline (GitHub Actions) will automatically:
- Create a new "Version Packages" pull request that includes version bumps and changelog updates
-
Review the "Version Packages" pull request:
- Check that the version bumps and changelog entries are correct
- Make any necessary adjustments
- Approve the pull request
-
Merge the "Version Packages" pull request:
- This triggers the publish workflow
-
The publish workflow will automatically:
- Publish the updated packages to our npm registry
- Push the new version tags to the repository