This document outlines the process for releasing new versions of sceni-code.
Before releasing, ensure you have:
- Push access to the repository
- NPM publish permissions for the
@scenius/sceni-codepackages - Docker Hub credentials configured as GitHub secrets:
DOCKER_USERNAMEDOCKER_PASSWORD
- NPM token configured as GitHub secret:
NPM_TOKEN
- Ensure all changes are merged to the
mainbranch - Run the full test suite locally:
npm run preflight
- Update the version in the root
package.jsonand workspace packages:Wherenpm version <version> --no-git-tag-version npm version <version> --no-git-tag-version --workspaces
<version>is the new version (e.g.,1.0.0,1.0.1, etc.)
- Commit the version changes:
git add -A git commit -m "chore: release v<version>" - Create and push a tag:
git tag v<version> git push origin main git push origin v<version>
Once the tag is pushed, the following will happen automatically:
-
NPM Release (
npm-release.yml):- Runs tests
- Builds all packages
- Publishes to NPM registry
- Creates a GitHub release
-
Docker Build (
docker-build.yml):- Builds the Docker image
- Tags with version, major.minor, major, and SHA
- Pushes to Docker Hub
If you need to release manually:
-
Trigger the NPM release workflow:
- Go to Actions → NPM Release → Run workflow
- Enter the version number (without 'v' prefix)
-
The Docker build will automatically trigger on the main branch push
Follow semantic versioning (semver):
- MAJOR version for incompatible API changes
- MINOR version for backwards-compatible functionality additions
- PATCH version for backwards-compatible bug fixes
After a successful release:
- Verify the packages are available on NPM
- Verify the Docker image is available on Docker Hub
- Update any documentation or changelog as needed
- Announce the release to users if applicable
- Ensure
NPM_TOKENsecret is valid - Check that the package name is not already taken
- Verify you have publish permissions
- Ensure
DOCKER_USERNAMEandDOCKER_PASSWORDsecrets are set - Check Docker Hub rate limits
- Verify the Dockerfile builds locally
- Run
npm run preflightlocally to reproduce - Fix any failing tests before releasing