This document defines versioning, changelog, and deployment procedures for the Tikka ecosystem.
- Semantic Versioning:
MAJOR.MINOR.PATCH - MAJOR: Breaking changes to public APIs (Raffle, Ticket, Wallet, User, Network, Utils modules)
- MINOR: New features, non-breaking additions, or marking public API as deprecated
- PATCH: Bug fixes, internal improvements
- Pre-release:
0.x.yduring development; increment MINOR for feature releases - Deprecation: Announce via JSDoc
@deprecated+CHANGELOG### Deprecated, keep for at least one MINOR cycle, remove only in a subsequent MAJOR (see sdk/DEPRECATION.md)
- Calendar Versioning:
YYYY.MM.PATCH - YYYY.MM: Release date (e.g.,
2026.05.0) - PATCH: Hotfixes within the same month
- No pre-release versions; deploy directly to staging/production
- Versioned by timestamp:
YYYYMMDD_HHMMSS_description.sql - Must be reversible (include rollback logic)
- Deployed independently of app versions
This monorepo uses Changesets to manage versioning and changelog generation.
-
Developer creates a changeset when making a change:
pnpm changeset
This creates a markdown file in
.changeset/describing the change and its semver bump type. -
Changesets are committed with the PR code.
-
CI bot (changeset-bot) comments on PRs missing changesets.
-
On merge to master, the
changesets/actioncreates/updates a "Version Packages" PR that:- Bumps versions in
package.jsonfiles - Updates
CHANGELOG.mdentries - When merged, tags the release and publishes to npm (SDK only)
- Bumps versions in
# Interactive prompt
pnpm changeset
# Select the package to version
# Choose bump type: patch / minor / major
# Write a summary of the changes (this becomes the CHANGELOG entry)Each changeset is a markdown file in .changeset/:
---
"@tikka/sdk": minor
"tikka-backend": patch
---
Add new raffle metadata endpoint for mobile clients.The changesets/action GitHub Action automatically creates a PR titled "Version Packages" when changesets accumulate on master. Merging this PR:
- Bumps versions in all affected
package.jsonfiles - Generates
CHANGELOG.mdentries from changeset files - Removes consumed
.changeset/*.mdfiles - Tags the commit with the release version
If the automated flow is unavailable:
# Consume all changesets and bump versions
pnpm changeset version
# Review generated CHANGELOG.md entries
git add -A
git commit -m "Version Packages"
git tag sdk-v0.2.0 # or appropriate tag
# Publish SDK to npm
cd sdk && npm publish- Create changesets for each user-facing change
- Push to master; "Version Packages" PR is created automatically
- Review and merge the PR
- CI tags and publishes to npm
- Update version in
sdk/package.json - Add entry to
CHANGELOG.mdusing the SDK section template (also summarized below) - Confirm deprecations/removals follow sdk/DEPRECATION.md
- Tag commit:
sdk-v0.1.0 - Publish to npm:
npm publish(fromsdk/directory) - Update TypeDoc:
npm run docs
- Update version in package.json (if applicable)
- Add entry to
CHANGELOG.md - Tag commit:
app-YYYY.MM.PATCH(e.g.,app-2026.05.0) - Deploy to staging, run integration tests
- Deploy to production
- Create migration file in
backend/migrations/ - Include rollback procedure in comments
- Test locally:
npm run migrate:upandnpm run migrate:down - Deploy before app release
- Document in
CHANGELOG.md
Entries are auto-generated from changeset files. Manual entries (if needed):
## [0.1.0] - 2026-05-28
### Added
- New feature description
### Changed
- Breaking change or significant modification
### Fixed
- Bug fix description
### Deprecated
- Deprecated API or feature
### Removed
- Removed feature or API
### Migration
- Database schema changes
- Rollback procedure (if applicable)
### Dependencies
- Updated or added dependencies| Package | Tag Format | Example |
|---|---|---|
| SDK | sdk-vMAJOR.MINOR.PATCH |
sdk-v0.2.0 |
| Client | app-YYYY.MM.PATCH |
app-2026.05.0 |
| Backend | app-YYYY.MM.PATCH |
app-2026.05.0 |
| Indexer | app-YYYY.MM.PATCH |
app-2026.05.0 |
| Oracle | app-YYYY.MM.PATCH |
app-2026.05.0 |
| Database | db-YYYYMMDD_HHMMSS |
db-20260528_143000 |
The docs.yml workflow deploys SDK documentation to GitHub Pages when:
- Code is pushed to
masterbranch, OR - An SDK tag (
sdk-v*) is pushed
Important: Docs only deploy for SDK tags. App or database tags do not trigger a docs deploy.
- Changesets created for all user-facing changes
- Tests pass (
npm test) - TypeDoc builds (
npm run docs) - No breaking changes to public APIs, or MAJOR version bumped
- "Version Packages" PR reviewed and merged
- All package tests pass
- Root build passes
- Database migrations tested (if applicable)
- Staging deployment successful
- Integration tests pass
- Changelog entry added
- Production deployment scheduled
- Migration is reversible
- Rollback tested locally
- No data loss in rollback
- Deployed before app release
npm unpublish @tikka/sdk@0.1.0
git revert <commit-hash>
git push- Revert to previous tag:
git revert <tag> - Redeploy previous version
- Notify team of rollback reason
- Run rollback migration:
npm run migrate:down - Verify data integrity
- Redeploy app if needed
When multiple packages release together:
- Coordinate versions and changelog entries
- Tag all commits with a release date:
release-2026.05.28 - Deploy in order: Database → Backend → Indexer/Oracle → Client
- Verify each step before proceeding
- Document in main
CHANGELOG.md
- Update
sdk/package.jsonversion - TypeDoc automatically reflects version in generated docs
- Public APIs should reference version in JSDoc comments for breaking changes
- Update
package.jsonversion (if applicable) - Include version in deployment metadata (e.g., Docker image tags)
- Log version on startup for debugging