$npx -y skills add minghinmatthewlam/agent-guards --skill ios-releaseRun a preflight-gated iOS release workflow with asc for TestFlight and App Store: auth check, ID resolution, validation, blocker triage, then controlled publish/submit commands. Use when: (1) shipping to TestFlight, (2) preparing App Store submission, (3) diagnosing release block
| 1 | # iOS Release (ASC) |
| 2 | |
| 3 | ## Goal |
| 4 | Use one release skill for both TestFlight and App Store flows with a strict gate: |
| 5 | - Phase A: read-only preflight |
| 6 | - Phase B: mutating execution (only after explicit approval) |
| 7 | |
| 8 | ## Reference map (load only when needed) |
| 9 | - `references/id-resolution-and-cli.md`: auth, output formats, ID lookup, pagination, timeouts. |
| 10 | - `references/testflight-orchestration.md`: groups, testers, notes, distribution operations. |
| 11 | - `references/submission-health.md`: encryption/compliance, metadata checks, submission error recovery. |
| 12 | - `references/workflow-automation.md`: `.asc/workflow.json` validation and CI-safe automation. |
| 13 | |
| 14 | ## Required inputs |
| 15 | - `APP_ID` |
| 16 | - `VERSION_ID` (for App Store validation/submission) |
| 17 | - `BUILD_ID` (for TestFlight validation/submission) |
| 18 | - IPA path for upload/publish flows |
| 19 | |
| 20 | ## Phase A: Preflight (read-only, default) |
| 21 | |
| 22 | ### 0) Auth and environment health |
| 23 | ```bash |
| 24 | asc auth status --verbose |
| 25 | asc doctor |
| 26 | ``` |
| 27 | |
| 28 | ### 1) Resolve and verify release identifiers |
| 29 | ```bash |
| 30 | asc apps list --limit 20 --output json |
| 31 | asc versions list --app "<APP_ID>" --limit 20 --output json |
| 32 | asc builds list --app "<APP_ID>" --limit 20 --output json |
| 33 | asc testflight beta-groups list --app "<APP_ID>" --output json |
| 34 | ``` |
| 35 | |
| 36 | ### 2) Pipeline state snapshot |
| 37 | ```bash |
| 38 | asc status --app "<APP_ID>" --output json |
| 39 | asc review submissions-list --app "<APP_ID>" --limit 10 --output json |
| 40 | ``` |
| 41 | |
| 42 | ### 3) Validation gates |
| 43 | TestFlight gate: |
| 44 | ```bash |
| 45 | asc validate testflight --app "<APP_ID>" --build "<BUILD_ID>" --output json |
| 46 | ``` |
| 47 | |
| 48 | App Store gate: |
| 49 | ```bash |
| 50 | asc validate --app "<APP_ID>" --version-id "<VERSION_ID>" --output json |
| 51 | ``` |
| 52 | |
| 53 | If any validation returns blocking errors: |
| 54 | - stop execution mode |
| 55 | - return a prioritized blocker checklist |
| 56 | - include the exact remediation command or ASC UI field for each blocker |
| 57 | - if blockers involve encryption/content-rights/localizations, load `references/submission-health.md` |
| 58 | |
| 59 | ## Phase B: Execute (mutating; explicit approval required) |
| 60 | |
| 61 | ### Route 1: TestFlight publish |
| 62 | One-shot path: |
| 63 | ```bash |
| 64 | asc publish testflight \ |
| 65 | --app "<APP_ID>" \ |
| 66 | --ipa "<PATH_TO_IPA>" \ |
| 67 | --group "<GROUP_ID_OR_NAME>" \ |
| 68 | --wait \ |
| 69 | --output json |
| 70 | ``` |
| 71 | |
| 72 | Optional notes and notifications: |
| 73 | ```bash |
| 74 | asc publish testflight \ |
| 75 | --app "<APP_ID>" \ |
| 76 | --ipa "<PATH_TO_IPA>" \ |
| 77 | --group "<GROUP_ID_OR_NAME>" \ |
| 78 | --test-notes "<WHAT_TO_TEST>" \ |
| 79 | --locale "en-US" \ |
| 80 | --wait \ |
| 81 | --notify \ |
| 82 | --output json |
| 83 | ``` |
| 84 | |
| 85 | If validation flags missing beta review fields, see `references/submission-health.md` for review detail recovery commands. |
| 86 | |
| 87 | ### Route 2: App Store publish and submission |
| 88 | One-shot publish: |
| 89 | ```bash |
| 90 | asc publish appstore \ |
| 91 | --app "<APP_ID>" \ |
| 92 | --ipa "<PATH_TO_IPA>" \ |
| 93 | --version "<VERSION_STRING>" \ |
| 94 | --wait \ |
| 95 | --output json |
| 96 | ``` |
| 97 | |
| 98 | Publish and submit: |
| 99 | ```bash |
| 100 | asc publish appstore \ |
| 101 | --app "<APP_ID>" \ |
| 102 | --ipa "<PATH_TO_IPA>" \ |
| 103 | --version "<VERSION_STRING>" \ |
| 104 | --wait \ |
| 105 | --submit \ |
| 106 | --confirm \ |
| 107 | --output json |
| 108 | ``` |
| 109 | |
| 110 | Manual submission path: |
| 111 | ```bash |
| 112 | asc submit create \ |
| 113 | --app "<APP_ID>" \ |
| 114 | --version-id "<VERSION_ID>" \ |
| 115 | --build "<BUILD_ID>" \ |
| 116 | --confirm \ |
| 117 | --output json |
| 118 | |
| 119 | asc submit status --version-id "<VERSION_ID>" --output json |
| 120 | ``` |
| 121 | |
| 122 | If validation flags missing app review fields, see `references/submission-health.md` for review detail recovery commands. |
| 123 | |
| 124 | ## Release checklist output format |
| 125 | For each release run, return: |
| 126 | - route (`testflight` or `appstore`) |
| 127 | - identifiers used (`APP_ID`, `VERSION_ID`, `BUILD_ID`) |
| 128 | - preflight status (pass/fail + blocker count) |
| 129 | - executed mutating commands |
| 130 | - resulting submission/build IDs |
| 131 | - next manual step (if any) |
| 132 | |
| 133 | ## Guardrails |
| 134 | - Never run mutating commands in preflight mode. |
| 135 | - Never submit (`--confirm`) without explicit user approval in the current session. |
| 136 | - Prefer deterministic IDs over names when both are available. |
| 137 | - Keep JSON output for machine-readability; use table only for quick human scans. |
| 138 | - If `.asc/workflow.json` exists, validate before CI use: |
| 139 | ```bash |
| 140 | asc workflow validate |
| 141 | ``` |
| 142 | - If a step needs details not in this file, load only the relevant reference file from this skill. |