generated from Kentico/repo-template
-
Notifications
You must be signed in to change notification settings - Fork 4
How to release a new version of Smart Link SDK
Vladislav Bulyukhin edited this page Jul 22, 2024
·
1 revision
The repository supports both automatic and manual release methods for publishing the npm package. Automatic release is recommended. Manual release steps are provided for information purposes.
The repository uses a GitHub Action for automatic publishing. The pipeline configuration can be found here. The automatic release requires the NPM_API_KEY
secret to be set in the repository/organization settings.
- Create a new branch from
master
. For example,release-x.x.x
. - Ensure all tests pass and everything works as expected.
- Update CHANGELOG:
- Add a new version tag in the CHANGELOG file, e.g.,
[1.2.3]
. - Move all changes from
[Unreleased]
to this new tag. - At the end of the file, add a link for the new tag, e.g.,
[1.2.3](https://...)
.
- Add a new version tag in the CHANGELOG file, e.g.,
- Run
npm version [patch|minor|major]
to update the package version and create a new tag. - Push your changes to the repository, create a PR and merge it.
- Create GitHub release:
- Use the new version as the release and tag name.
- For
@next
tag releases (e.g., beta versions), mark the release aspre-release
. Otherwise, mark it as latest.
- Wait for the GitHub Action to start and release the package. Monitor its progress on the Actions tab.
If needed, you can release a new version manually. Ensure your npm account is included in the collaborators list of the Kontent.ai organization.
- Follow steps 1 to 5 from the Automatic Release section.
- Run
npm publish --dry-run
to verify the package is ready for publishing. - If the dry run is successful, publish the new version using
npm publish
.
- Create a new release branch from
master
or your working branch. For example,release-x.x.x-next.x
. - Ensure all tests pass and everything works as expected.
- Run
npm version [prerelease|prepatch|preminor|premajor] --preid=next
to update the package version. - Push your changes to the repository and open a PR.
- Publish the package using
npm publish --tag next
. - Merge your PR.