Skip to content

Commit 8e95e56

Browse files
committed
chore(ios): generate release artifacts locally
1 parent 4a2a977 commit 8e95e56

26 files changed

Lines changed: 247 additions & 330 deletions

‎.github/workflows/ios-periphery.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ jobs:
102102
set -euo pipefail
103103
./scripts/ios-configure-signing.sh
104104
./scripts/ios-write-version-xcconfig.sh
105+
node scripts/ios-write-swift-filelist.mjs
105106
cd apps/ios
106107
xcodegen generate
107108

‎.gitignore‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ apps/android/fastlane/README.md
8181
apps/ios/fastlane/report.xml
8282
apps/ios/fastlane/Preview.html
8383
apps/ios/fastlane/screenshots/
84+
apps/ios/fastlane/metadata/*/release_notes.txt
8485
apps/ios/fastlane/test_output/
8586
apps/ios/fastlane/logs/
8687
apps/ios/fastlane/.env

‎apps/ios/Config/Signing.xcconfig‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// Shared iOS signing defaults for local development + CI.
2-
#include "Version.xcconfig"
2+
#include "../build/Version.xcconfig"
33

44
OPENCLAW_IOS_DEFAULT_TEAM = FWJYW4S8P8
55
OPENCLAW_IOS_SELECTED_TEAM = $(OPENCLAW_IOS_DEFAULT_TEAM)

‎apps/ios/Config/Version.xcconfig‎

Lines changed: 0 additions & 9 deletions
This file was deleted.

‎apps/ios/README.md‎

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,7 @@ OpenClaw iOS is the officially released iPhone app. It connects to an OpenClaw G
2525

2626
```bash
2727
pnpm install
28-
./scripts/ios-configure-signing.sh
29-
cd apps/ios
30-
xcodegen generate
31-
open OpenClaw.xcodeproj
28+
pnpm ios:open
3229
```
3330

3431
3. In Xcode:
@@ -40,10 +37,10 @@ open OpenClaw.xcodeproj
4037
- Use unique local bundle IDs via `apps/ios/LocalSigning.xcconfig`.
4138
- Start from `apps/ios/LocalSigning.xcconfig.example`.
4239

43-
Shortcut command (same flow + open project):
40+
Generate without opening Xcode:
4441

4542
```bash
46-
pnpm ios:open
43+
pnpm ios:gen
4744
```
4845

4946
## App Store Release Flow
@@ -165,10 +162,10 @@ This should create `apps/ios/fastlane/.env` with non-secret App Store Connect va
165162

166163
Use `pnpm ios:release:signing:setup` for the initial portal setup, then `MATCH_PASSWORD=... pnpm ios:release:signing:sync:push` to publish encrypted Fastlane match assets to the shared private repo.
167164

168-
4. If you are starting a brand-new production release train, add or update the matching iOS changelog section and sync generated metadata:
165+
4. If you are starting a brand-new production release train, add or update the matching iOS changelog section and validate the release notes:
169166

170167
```bash
171-
pnpm ios:version:sync -- --version 2026.6.11
168+
pnpm ios:version:check -- --version 2026.6.11
172169
```
173170

174171
5. Upload the build with explicit release intent:
@@ -183,7 +180,7 @@ pnpm ios:release:upload -- --version 2026.6.11 --build-number 3
183180

184181
7. Expected behavior:
185182
- Fastlane reads the explicit `--version` value
186-
- verifies synced iOS versioning artifacts for that version
183+
- validates iOS versioning inputs for that version
187184
- resolves the next App Store Connect build number for that short version
188185
- generates deterministic App Store screenshots
189186
- uploads release notes, screenshots, and the App Review PDF attachment to the editable App Store version
@@ -205,16 +202,17 @@ pnpm ios:release:upload -- --version 2026.6.11 --build-number 3
205202
- Release upload version: explicit `--version`
206203
- Local default version: root `package.json`
207204
- iOS-only changelog: `apps/ios/CHANGELOG.md`
208-
- Generated checked-in artifacts:
209-
- `apps/ios/Config/Version.xcconfig`
210-
- `apps/ios/fastlane/metadata/en-US/release_notes.txt`
205+
- Generated local artifacts:
206+
- `apps/ios/build/Version.xcconfig`
207+
- `apps/ios/SwiftSources.input.xcfilelist`
208+
- temporary Fastlane metadata containing release notes rendered from `apps/ios/CHANGELOG.md`
211209
- Useful commands:
212210

213211
```bash
214212
pnpm ios:version
215213
pnpm ios:version:check
216214
pnpm ios:version -- --version 2026.6.11
217-
pnpm ios:version:sync -- --version 2026.6.11
215+
pnpm ios:filelist:gen
218216
```
219217

220218
Recommended flow:
@@ -223,15 +221,15 @@ Recommended flow:
223221

224222
1. Choose the App Store train explicitly, for example `2026.6.11`.
225223
2. Update `apps/ios/CHANGELOG.md`, usually under `## Unreleased` while iterating.
226-
3. Run `pnpm ios:version:sync -- --version 2026.6.11` after changelog changes.
224+
3. Run `pnpm ios:version:check -- --version 2026.6.11` after changelog changes.
227225
4. Upload additional App Store Connect builds with `pnpm ios:release:upload -- --version 2026.6.11`.
228226
5. Let Fastlane bump only the numeric build number.
229227

230228
### Starting the next production release train
231229

232230
1. Confirm the target gateway version in root `package.json`.
233231
2. Update `apps/ios/CHANGELOG.md` for the new release as needed.
234-
3. Run `pnpm ios:version:sync -- --version <release-version>`.
232+
3. Run `pnpm ios:version:check -- --version <release-version>`.
235233
4. Submit the first App Store Connect build with `pnpm ios:release:upload -- --version <release-version>`.
236234
5. Keep iterating on that same explicit version until the release candidate is ready.
237235

‎apps/ios/Signing.xcconfig‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// Auto-selected local team overrides live in .local-signing.xcconfig (git-ignored).
33
// Manual local overrides can go in LocalSigning.xcconfig (git-ignored).
44

5-
#include "Config/Version.xcconfig"
5+
#include "build/Version.xcconfig"
66

77
OPENCLAW_CODE_SIGN_STYLE = Manual
88
OPENCLAW_CODE_SIGN_IDENTITY = Apple Development

‎apps/ios/SwiftSources.input.xcfilelist‎

Lines changed: 0 additions & 153 deletions
This file was deleted.

‎apps/ios/VERSIONING.md‎

Lines changed: 19 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ upload fully deterministic.
5454
### Source files
5555

5656
- `package.json`
57-
- default iOS version source for local builds and checked-in defaults
57+
- default iOS version source for local builds
5858
- explicit `--version`
5959
- release upload source of truth
6060
- `apps/ios/CHANGELOG.md`
@@ -64,26 +64,28 @@ upload fully deterministic.
6464

6565
### Generated or derived files
6666

67-
- `apps/ios/Config/Version.xcconfig`
68-
- checked-in defaults derived from `package.json` or `pnpm ios:version:sync -- --version ...`
69-
- `apps/ios/fastlane/metadata/en-US/release_notes.txt`
70-
- generated from `apps/ios/CHANGELOG.md`
7167
- `apps/ios/build/Version.xcconfig`
7268
- local gitignored build override generated per build or release prep
69+
- `apps/ios/SwiftSources.input.xcfilelist`
70+
- local gitignored Swift lint input file generated before Xcode project generation
71+
- temporary Fastlane metadata
72+
- release notes generated from `apps/ios/CHANGELOG.md` during metadata upload
7373

7474
## Tooling surfaces
7575

7676
- `scripts/lib/ios-version.ts`
7777
- validates iOS CalVer
7878
- normalizes gateway version -> iOS CalVer
79-
- renders checked-in xcconfig and release notes
79+
- renders release notes from the iOS changelog
8080
- `scripts/ios-version.ts`
8181
- CLI for JSON, shell, or single-field version reads
8282
- accepts `--version YYYY.M.D` for explicit release queries
8383
- `scripts/ios-sync-versioning.ts`
84-
- syncs checked-in derived files from the default or explicit iOS version
84+
- validates that release notes can be rendered from the default or explicit iOS version
8585
- `scripts/ios-write-version-xcconfig.sh`
8686
- writes the local numeric build override file in `apps/ios/build/Version.xcconfig`
87+
- `scripts/ios-write-swift-filelist.mjs`
88+
- writes the local Swift file list consumed by Xcode pre-build lint phases
8789
- `scripts/ios-release-prepare.sh`
8890
- requires `--version` and prepares App Store distribution signing and bundle settings
8991
- `apps/ios/fastlane/Fastfile`
@@ -102,17 +104,17 @@ Store Connect mutation commands.
102104

103105
## Release-note resolution order
104106

105-
When generating `apps/ios/fastlane/metadata/en-US/release_notes.txt`, the
106-
tooling reads the first available changelog section in this order:
107+
When generating the temporary Fastlane release notes metadata, the tooling reads
108+
the first available changelog section in this order:
107109

108110
1. exact release version, for example `## 2026.6.11`
109111
2. `## Unreleased`
110112

111-
Before production upload, prefer a final `## <release version>` section and run
112-
sync with the same version:
113+
Before production upload, prefer a final `## <release version>` section and
114+
validate with the same version:
113115

114116
```bash
115-
pnpm ios:version:sync -- --version 2026.6.11
117+
pnpm ios:version:check -- --version 2026.6.11
116118
```
117119

118120
## Common commands
@@ -121,15 +123,15 @@ pnpm ios:version:sync -- --version 2026.6.11
121123
pnpm ios:version
122124
pnpm ios:version -- --version 2026.6.11
123125
pnpm ios:version:check
124-
pnpm ios:version:sync -- --version 2026.6.11
126+
pnpm ios:filelist:gen
125127
pnpm ios:release:upload -- --version 2026.6.11 --build-number 3
126128
```
127129

128130
## Normal App Store Connect build iteration workflow
129131

130132
1. choose the App Store release train explicitly, for example `2026.6.11`
131133
2. update `apps/ios/CHANGELOG.md` under `## <release version>` or `## Unreleased`
132-
3. run `pnpm ios:version:sync -- --version <release version>`
134+
3. run `pnpm ios:version:check -- --version <release version>`
133135
4. check App Store Connect for the latest build number when needed
134136
5. upload another build with `pnpm ios:release:upload -- --version <release version> --build-number <next>`
135137

@@ -182,10 +184,10 @@ node -e "console.log(require('./package.json').version)"
182184
```
183185

184186
2. update `apps/ios/CHANGELOG.md` for that release
185-
3. sync iOS generated files:
187+
3. validate iOS release notes:
186188

187189
```bash
188-
pnpm ios:version:sync -- --version 2026.6.11
190+
pnpm ios:version:check -- --version 2026.6.11
189191
```
190192

191193
4. verify live App Store Connect state and choose the next build number
@@ -201,7 +203,7 @@ pnpm ios:release:upload -- --version 2026.6.11 --build-number 3
201203
## Important invariant
202204

203205
App Store uploads must carry explicit version intent. Do not infer a release
204-
train from checked-in generated files.
206+
train from generated local files.
205207

206208
App Review submission remains manual. Automation may create/update the editable
207209
App Store version, upload screenshots, upload release notes, upload the App

0 commit comments

Comments
 (0)