Releasing the Gem
cm-admin is published to the private CM Gems registry via two manually dispatched GitHub workflows: a stable release from main and a beta release from beta.
Stable Release — release-cm-gem.yml
Workflow name: Bump Gem to CM Gems
Trigger: Manual (workflow_dispatch) — must run on the main branch
Input
| Input | Type | Options | Default | Description |
|---|---|---|---|---|
bump_type | choice | patch, minor, major | patch | Semantic version segment to bump via gem-release |
Pipeline
build (main branch only)
├─ Checkout with MARVIN_GH_PAT
├─ Set up Ruby 3.4 + bundler cache
├─ gem install gem-release
├─ gem bump --version <bump_type> → updates lib/cm_admin/version.rb
├─ bundle install → refreshes Gemfile.lock
└─ Commit & push to main → "Add bundle files"
release (needs: build)
├─ Checkout + git pull
├─ gem build cm_admin.gemspec
├─ Read version from CmAdmin::VERSION → exposed as job output
└─ ./upload.sh $CM_GEMS_PASSWORD $CM_GEMS_HOST
changelog (needs: release)
└─ Calls changelog-release.yml with version=v<version>
→ AI release notes, GitHub Release, docs update, Slack notification
(see Release Changelog & Notifications)
Secrets & Variables
| Name | Kind | Purpose |
|---|---|---|
MARVIN_GH_PAT | secret | Checkout and push version-bump commits |
CM_GEMS_PASSWORD | var | Password for the private gem host |
CM_GEMS_HOST | var | Hostname of the private gem registry |
OPENROUTER_API_KEY, SLACK_WEBHOOK_URL | secret | Passed through to the changelog workflow |
Beta Release — release-beta-gem.yml
Workflow name: Release Beta Version to CM Gems
Trigger: Manual (workflow_dispatch) — must run on the beta branch
How Beta Versioning Works
- Reads the base version from
CmAdmin::VERSIONand strips any existing.betasuffix - Counts existing git tags matching
v<base>.beta*to determine the next beta number - Writes
<base>.beta<N>intolib/cm_admin/version.rb(e.g.7.2.26.beta1,7.2.26.beta2, …) - Commits the version bump to
beta, builds the gem, and pushes to CM Gems - Creates a GitHub pre-release tag
v<base>.beta<N>viasoftprops/action-gh-release
Beta releases do not trigger the changelog workflow — they are pre-releases for testing only.
Notes
- Both workflows abort early if dispatched from the wrong branch (
main/betarespectively) bundle config set frozen falseis set beforebundle installsoGemfile.lockcan be updated during the bump- The stable release's changelog step runs after the gem is pushed, so a changelog failure never blocks the gem publish