Repository navigation
feat(ci): dispatch Codemagic releases from GitHub Actions - #8
Merged
Merged
Conversation
Add a workflow_dispatch Release workflow, as in Martie. On a main commit whose CI passed it pushes the tag Codemagic builds from: v<version> plus a GitHub Release for store builds, annotated ota-<version>-<n> for a Patch OTA, or ota-dry-<version>-<n> for the same run without the upload. Pushing the tag by hand still works when Actions cannot run. scripts/ota-release.zsh now runs `expo prebuild --no-install --clean` for each platform inside the production env:exec call, right before `cmpatch release-react`. Patch fingerprints the generated native projects and a clean clone has none, so the first real OTA would otherwise fail. On Codemagic (CM_BUILD_ID) the script accepts a tag anywhere on main, since main may move while the build queues, and runs CI's check commands itself. OTA_DRY_RUN now builds the bundle and fingerprint with `release-react --dry-run` instead of stopping after the gates. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Releases can now be started from GitHub Actions alone, the same way Martie does it at
f960d1c.Release dispatch workflow (
.github/workflows/release.yml)workflow_dispatchwithkindandmessage. It only tags a main commit whose CI passed. Codemagic's webhook does the rest.storev<package.json version>+ GitHub Releaseios-production,android-production(TestFlight, Play internal draft)otaota-<version>-<n>ota-production(Patch Production)ota-dryota-dry-<version>-<n>Example:
gh workflow run Release -f kind=ota -f message="Fix the calendar total". Actions is usable here because the repo is public, so standard runners are free, and CI on main is green. When Actions cannot run, pushing the same tag by hand starts the identical Codemagic run.Prebuild before the OTA release (
scripts/ota-release.zsh)expo prebuild --no-install --cleannow runs inside the productioneas env:execcall, right beforecmpatch release-react. Patch fingerprints the generated native projects. On a clean clone,cmpatch fingerprintfails with "no ios native project sources were found", so the first real OTA would have failed.BOOKOO_BUILD_NUMBER. They are identical (iOS5461…, Androidfbc6…), so the store build number does not affect compatibility.CM_BUILD_ID), the script accepts a tag anywhere on main and runs CI's check commands itself. Main can move while the build queues. Locally, the exact-main and CI gates are unchanged.OTA_DRY_RUNnow runs the full build (prebuild, bundle, fingerprint) throughrelease-react --dry-runand skips only the upload.codemagic.yaml:ota-productionnow checks the Patch login first and no longer runs its own tip-of-main step. The script owns that gate.Verification
CM_BUILD_IDset,OTA_DRY_RUN=1) on a clean worktree of main with these files:Finished prebuild→Computing native fingerprint...→Dry run complete.075fc227…, Android001d2685….bun checkpasses (1751 tests).bun lint:allreports 0 errors; the 22 warnings match main.actionlintis clean,zsh -npasses, and both YAML files parse.test/release/otaRelease.test.tscover the prebuild order, the dry-run flag, the Codemagic ancestry gate, and the Release tag formats.ota-drydispatch, run end to end through Actions and Codemagic.🤖 Generated with Claude Code