/apple-dev-skills:xcode-cloud-single-track-cifrom apple-dev-skills
Sets up single-track CI for Apple-platform projects on Xcode Cloud: PR/Main/Release/scheduled workflows, ci_scripts hooks, and build number wiring via CI_BUILD_NUMBER and agvtool.
Ships in apple-dev-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
ci_scripts/ci_post_clone.sh / ci_pre_xcodebuild.sh / ci_post_xcodebuild.sh.| Workflow | Trigger | Action |
|---|---|---|
| PR CI | PR open / push — Pull Request Changes start condition (Xcode Cloud merges the PR with the target branch before building) | Build + Test (unit / integration with fakes / snapshot) |
| Main CI | Merge to main | Build + Archive + upload to internal TestFlight; do not re-run tests (already verified by PR CI in pre-merged state) |
| Release | git tag v* | Build + upload to App Store Connect (manual submission for review) |
| Periodic / Manual | Scheduled + manual trigger | Project-specific batch jobs (nightly export, metadata updates, etc.) |
Scheduling granularity caveat: Xcode Cloud's "On a Schedule" start condition lets you specify the frequency, time, and branch (Apple's own example: "every business day at 10:00 p.m."); it does not expose arbitrary cron expressions. For a cadence the frequency picker can't express directly (e.g. monthly), pick the closest supported frequency and add a script-side date guard inside
ci_post_clone.shthat early-exits when the date doesn't match the desired condition.
foundations.md toolchain line.bin/mise wrapper (mise generate install-script --localize --write bin/mise, from mise-tool-management — requires mise ≥ 2026.8.11; on older mise run mise self-update, or use the old mise generate bootstrap --localize --write bin/mise, which newer mise keeps as a deprecated alias with removal planned for mise 2027.9.0) and call every tool inside ci_scripts/ through it (./bin/mise trust, ./bin/mise install, ./bin/mise exec -- <tool> <args>) instead of a bare mise invocation, which fails with "command not found".| Need | Setting / source | Where it's set | Action |
|---|---|---|---|
| User-visible version | MARKETING_VERSION (→ CFBundleShortVersionString) | Project build settings | Bump deliberately per release |
| Build number, new iOS app | CI_BUILD_NUMBER | Xcode Cloud (sequential integer per build, starting at 1, independent of CURRENT_PROJECT_VERSION) | Nothing — a version+build pair lower than a prior manually-numbered build is still valid on iOS, even though Apple's docs call that same pattern invalid for a Mac app (see next row; worked example: references/official-docs.md) |
| Build number, existing Mac app with a prior higher build | ASC's Xcode Cloud build-number counter | App Store Connect → app → Xcode Cloud tab → Settings → Build Number tab → Edit | Set the next build number above your last shipped one (macOS requires the build number to strictly increase across versions, not just be unique within one) |
Binary must carry the CI build number (e.g. crash-symbolication tooling that reads CURRENT_PROJECT_VERSION) | agvtool new-version -all "$CI_BUILD_NUMBER" in ci_post_clone.sh | Repo | Requires VERSIONING_SYSTEM = apple-generic (agvtool enabled) on the target |
Release tooling that mints versionString for the ASC API (→ asc-api-automation) should read this project's MARKETING_VERSION rather than track a second version counter — one SemVer source of truth.
Apple provides:
ci_post_clone.sh — runs right after clone, before any build resources are spent (secret scan, the bin/mise bootstrap go here, cheapest stage)ci_pre_xcodebuild.sh — before buildci_post_xcodebuild.sh — after buildMinimal ci_post_clone.sh, using the committed bin/mise wrapper (see Environment lock above):
#!/bin/sh
set -eu
cd "$CI_PRIMARY_REPOSITORY_PATH"
./bin/mise trust
./bin/mise install
./bin/mise exec -- swiftlint lint
nektos/act to reproduce non-build jobs locallyStarting point: when one of the above real pain points appears, add a single workflow first, don't go dual-track in one shot.
When two PRs each pass pre-merge and merge back to back, their combined result was never tested.
foundations.md toolchain line.bin/mise is committed; ci_post_clone.sh starts with cd "$CI_PRIMARY_REPOSITORY_PATH", then runs ./bin/mise trust && ./bin/mise install, not a bare mise call.mise-tool-management: ci_scripts/ tools installed via mise.swift-testing-baseline: CI skips real-network integration tests.apple-public-repo-security: PR CI adds a gitleaks step as the second line of defence.apple-platform-targets: Xcode version lock.asc-api-automation: release-side versionString and changelog automation, once the build exists in ASC — reuses this project's MARKETING_VERSION / CI_BUILD_NUMBER.local-archive-export-upload: the manual fallback when Xcode Cloud is down or its quota is exhausted.references/official-docs.md.What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
28 skills in this plugin
/ai-translated-localizationLocalization scope and AI-translation execution for Apple-platform Apps on `Localizable.xcstrings` — default locale set, source / primary language rule, per-locale review gotchas, completeness gates. Use when deciding which locales to ship at project setup; when adding or refreshing user-facing strings (UI keys, Game Center, App Store metadata) in non-source locales; when `extractionState: stale` entries or untranslated placeholder markers appear; or when asked "how many locales", "how do translations enter git". Does NOT cover RTL layout or ASC upload mechanics → asc-api-automation./apple-platform-targetsDefault minimum deployment target for Apple-platform Swift Apps — iOS 26 / macOS 26 on the Xcode 26 toolchain (Swift 6 language mode) — and how to deviate down (iOS 18 / 17) or up. Use when starting a new Apple-platform project, writing the Package.swift `platforms:` list, deciding whether an API newer than the floor is worth bumping for or a client requirement forces dropping below it, or when asked "what should the minimum iOS / macOS version be". Entry point of the bootstrap chain; does NOT own language mode → swift6-concurrency, or module layout → swiftpm-modularization./apple-public-repo-securityUse when a repo goes public or open-sources, when a CloudKit server-to-server PEM, ASC API `.p8`, APNs key, signing `.p12`, or provisioning profile first enters the pipeline, or when asked how to prevent or respond to a secret leak (gitleaks, lefthook, GitHub Secret Scanning, `git filter-repo`, rotate-first). Also for Apple upstream telemetry disclosure (MetricKit, Game Center, sysdiagnose). Repo-hygiene baseline only; ship-in-binary identifiers (AdMob IDs via xcconfig) and CLI keys in `secrets/.env` are build-time-secret-injection; ASC API usage is asc-api-automation./apple-three-piece-analyticsChoose analytics and metrics sources for a solo / small-team Apple app and decide whether a third-party tracking SDK is justified. Use when picking an analytics SDK; when asked "should I add Firebase / Mixpanel / Amplitude / TelemetryDeck"; when asked what App Store Connect Analytics, MetricKit (`MXMetricPayload`) or Game Center can measure without an SDK; when the analytics choice drives `PrivacyInfo.xcprivacy` or forces ATT. Does NOT own MetricKit perf wiring (ios-performance-engineering), App Review privacy-label parity (app-store-review-rejections), or sink code (telemetry-facade-pattern)./app-store-review-rejectionsUse when preparing an App Store submission, reading an App Review rejection or Resolution Center message citing a guideline number (2.1, 2.3.x, 3.1.1, 4.3, 5.1.1, 5.1.2), or a privacy-manifest upload email (ITMS-91061 / ITMS-91056, missing required-reason API), or auditing an ads + Remove-Ads IAP + CloudKit + Game Center app for the rejection classes it realistically hits: the ATT-vs-AdMob trap, privacy-label parity with `PrivacyInfo.xcprivacy`, Restore Purchases, screenshot metadata, export compliance. Maps each class to a pre-submit fix. Not the submission mechanics (asc-api-automation) nor StoreKit implementation (storekit2-iap-defaults)./asc-api-automationUse when automating App Store Connect from a script or CI via the ASC REST API (`api.appstoreconnect.apple.com`) — ASC API `.p8` key / JWT auth, TestFlight `betaGroups` / `betaBuildLocalizations`, `appStoreVersions` / `releaseType`, `reviewSubmissions`, `salesReports`, `analyticsReportRequests` — or asked "automate TestFlight / submission / release notes", "should I use fastlane", or debugging 401 NOT_AUTHORIZED / 429 RATE_LIMIT_EXCEEDED, or asked which ASC steps have no API and must be clicked by hand. API side only: build & upload → xcode-cloud-single-track-ci / local-archive-export-upload; `.p8` storage → build-time-secret-injection.npx claudepluginhub wei18/apple-dev-skills --plugin apple-dev-skillsOther plugins' skills for the same job