From 400b57c30aafe78ae9a84f0f51dbbb4f98a467d2 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Thu, 29 Jan 2026 11:10:36 -0600 Subject: [PATCH 01/20] fix: ios ci test --- .github/workflows/example_ios_build.yml | 45 +++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 .github/workflows/example_ios_build.yml diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml new file mode 100644 index 0000000..f588a63 --- /dev/null +++ b/.github/workflows/example_ios_build.yml @@ -0,0 +1,45 @@ +name: Test Example App Build + +on: + pull_request: + branches: [main] + +jobs: + test-ios-build: + runs-on: macos-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20' + cache: 'npm' + + - name: Install dependencies (root) + run: npm ci + + - name: Install dependencies (example app) + working-directory: example + run: npm ci + + - name: Setup Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: '3.2' + bundler-cache: true + working-directory: example/ios + + - name: Install CocoaPods dependencies + working-directory: example/ios + run: pod install + + - name: Prebuild Expo app + working-directory: example + run: npx expo prebuild --clean --platform ios + + - name: Build iOS app + working-directory: example + run: npm run ios -- --no-install \ No newline at end of file From 6ce4c9ee586bfa3211175d33875f733a8943b9ea Mon Sep 17 00:00:00 2001 From: camrun01 Date: Thu, 29 Jan 2026 11:22:48 -0600 Subject: [PATCH 02/20] fix: change order of commands --- .github/workflows/example_ios_build.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index f588a63..d1648fd 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -25,6 +25,10 @@ jobs: working-directory: example run: npm ci + - name: Prebuild Expo app + working-directory: example + run: npx expo prebuild --clean --platform ios + - name: Setup Ruby uses: ruby/setup-ruby@v1 with: @@ -36,10 +40,6 @@ jobs: working-directory: example/ios run: pod install - - name: Prebuild Expo app - working-directory: example - run: npx expo prebuild --clean --platform ios - - name: Build iOS app working-directory: example run: npm run ios -- --no-install \ No newline at end of file From 3bb23946d27e98cd2d3c06d947fcaba41fbedec7 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Thu, 29 Jan 2026 12:17:49 -0600 Subject: [PATCH 03/20] fix: pin xcode --- .github/workflows/example_ios_build.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index d1648fd..2742d9f 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -12,6 +12,12 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 + # Pin Xcode so CI matches local dev; use a specific version (e.g. '16.2') to lock to team standard + - name: Select Xcode version + uses: maxim-lobanov/setup-xcode@v1 + with: + xcode-version: 'latest-stable' + - name: Setup Node.js uses: actions/setup-node@v4 with: From 0d249e2551f65153897e43bf9f2e9cbd4e5c3ade Mon Sep 17 00:00:00 2001 From: Cameron Llewellyn Date: Thu, 29 Jan 2026 12:37:15 -0600 Subject: [PATCH 04/20] Update .github/workflows/example_ios_build.yml Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> Signed-off-by: Cameron Llewellyn --- .github/workflows/example_ios_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 2742d9f..aae4aad 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -12,7 +12,7 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 - # Pin Xcode so CI matches local dev; use a specific version (e.g. '16.2') to lock to team standard + # Use latest stable Xcode; consider pinning to specific version (e.g. '16.2') if team needs consistency - name: Select Xcode version uses: maxim-lobanov/setup-xcode@v1 with: From 9d5961a3fce3f92158219db75dd3198e0ba23e28 Mon Sep 17 00:00:00 2001 From: Cameron Llewellyn Date: Thu, 29 Jan 2026 12:45:04 -0600 Subject: [PATCH 05/20] Update .github/workflows/example_ios_build.yml Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> Signed-off-by: Cameron Llewellyn --- .github/workflows/example_ios_build.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index aae4aad..1884fb6 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -4,9 +4,10 @@ on: pull_request: branches: [main] -jobs: test-ios-build: runs-on: macos-latest + permissions: + contents: read steps: - name: Checkout repository From 71f14ab5269372762002da30aff784c77b54540a Mon Sep 17 00:00:00 2001 From: Cameron Llewellyn Date: Mon, 2 Feb 2026 15:19:56 -0600 Subject: [PATCH 06/20] Update .github/workflows/example_ios_build.yml Co-authored-by: Jeff Hampton Signed-off-by: Cameron Llewellyn --- .github/workflows/example_ios_build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 1884fb6..b73f8d2 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -4,6 +4,7 @@ on: pull_request: branches: [main] +jobs: test-ios-build: runs-on: macos-latest permissions: From a940aecb04340a3233c8db48d001ec14fdc70b96 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 08:53:29 -0600 Subject: [PATCH 07/20] fix: simplify --- .github/workflows/example_ios_build.yml | 8 -------- 1 file changed, 8 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index b73f8d2..b99f9f3 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -33,10 +33,6 @@ jobs: working-directory: example run: npm ci - - name: Prebuild Expo app - working-directory: example - run: npx expo prebuild --clean --platform ios - - name: Setup Ruby uses: ruby/setup-ruby@v1 with: @@ -44,10 +40,6 @@ jobs: bundler-cache: true working-directory: example/ios - - name: Install CocoaPods dependencies - working-directory: example/ios - run: pod install - - name: Build iOS app working-directory: example run: npm run ios -- --no-install \ No newline at end of file From 6a9379db1078bed6529806af059faf8648e714d2 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 09:10:47 -0600 Subject: [PATCH 08/20] fix: resolve errors --- .github/workflows/example_ios_build.yml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index b99f9f3..c5a0dda 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -32,13 +32,14 @@ jobs: - name: Install dependencies (example app) working-directory: example run: npm ci + # Do this before ruby set up it creates the ios directory + - name: Generate native iOS project + working-directory: example + run: npx expo prebuild --platform ios - - name: Setup Ruby - uses: ruby/setup-ruby@v1 - with: - ruby-version: '3.2' - bundler-cache: true - working-directory: example/ios + - name: Install CocoaPods dependencies + working-directory: example/ios + run: bundle install - name: Build iOS app working-directory: example From 5d5c8bdef6d1b0391f7fb63869c7c1e03d046e1a Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 09:19:59 -0600 Subject: [PATCH 09/20] fix: command --- .github/workflows/example_ios_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index c5a0dda..2447477 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -39,7 +39,7 @@ jobs: - name: Install CocoaPods dependencies working-directory: example/ios - run: bundle install + run: pod install - name: Build iOS app working-directory: example From 987add51b5058d0a566ed427cbcbaed3866cd37e Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 11:47:00 -0600 Subject: [PATCH 10/20] fix: speed up build --- .github/workflows/example_ios_build.yml | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 2447477..ddd36ac 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -32,15 +32,29 @@ jobs: - name: Install dependencies (example app) working-directory: example run: npm ci - # Do this before ruby set up it creates the ios directory - name: Generate native iOS project working-directory: example run: npx expo prebuild --platform ios + - name: Cache CocoaPods + uses: actions/cache@v4 + id: pods-cache + with: + path: example/ios/Pods + key: ${{ runner.os }}-pods-${{ hashFiles('example/ios/Podfile', 'example/package-lock.json') }} + restore-keys: | + ${{ runner.os }}-pods- + - name: Install CocoaPods dependencies working-directory: example/ios run: pod install - - name: Build iOS app - working-directory: example - run: npm run ios -- --no-install \ No newline at end of file + - name: Build iOS app (no simulator launch) + working-directory: example/ios + run: | + xcodebuild -workspace react-native-sdk-example.xcworkspace \ + -scheme react-native-sdk-example \ + -configuration Debug \ + -sdk iphonesimulator \ + -destination 'generic/platform=iOS Simulator' \ + build \ No newline at end of file From 5f778380a10ec1c391cfeee9cab58d8515c84cbd Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 11:51:22 -0600 Subject: [PATCH 11/20] fix: command --- .github/workflows/example_ios_build.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index ddd36ac..8866b4d 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -52,8 +52,9 @@ jobs: - name: Build iOS app (no simulator launch) working-directory: example/ios run: | - xcodebuild -workspace react-native-sdk-example.xcworkspace \ - -scheme react-native-sdk-example \ + WORKSPACE=$(ls *.xcworkspace | head -1) + SCHEME=$(xcodebuild -list -workspace "$WORKSPACE" -json | jq -r '.workspace.schemes[0]') + xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" \ -configuration Debug \ -sdk iphonesimulator \ -destination 'generic/platform=iOS Simulator' \ From 4300b682f52cf96daa3431f5fcf608fffa82bae0 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 11:56:42 -0600 Subject: [PATCH 12/20] fix: command --- .github/workflows/example_ios_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 8866b4d..aa45911 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -52,7 +52,7 @@ jobs: - name: Build iOS app (no simulator launch) working-directory: example/ios run: | - WORKSPACE=$(ls *.xcworkspace | head -1) + WORKSPACE=$(ls -d *.xcworkspace | head -1) SCHEME=$(xcodebuild -list -workspace "$WORKSPACE" -json | jq -r '.workspace.schemes[0]') xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" \ -configuration Debug \ From 8951419f589a7ae6562413782222eccde80d4c0c Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 12:04:14 -0600 Subject: [PATCH 13/20] fix: confirm build --- .github/workflows/example_ios_build.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index aa45911..a2bd07b 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -58,4 +58,15 @@ jobs: -configuration Debug \ -sdk iphonesimulator \ -destination 'generic/platform=iOS Simulator' \ - build \ No newline at end of file + -derivedDataPath build \ + build + + - name: Verify build output + working-directory: example/ios + run: | + APP=$(find build/Build/Products/Debug-iphonesimulator -maxdepth 1 -name '*.app' -type d | head -1) + if [ -z "$APP" ]; then + echo "::error::No .app bundle found — build may have failed to produce output" + exit 1 + fi + echo "✅ iOS build verified: $(basename "$APP") produced successfully" \ No newline at end of file From 898a04709131c56d191acc3355d907e53364d63b Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 12:13:49 -0600 Subject: [PATCH 14/20] fix: path --- .github/workflows/example_ios_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index a2bd07b..5906917 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -64,7 +64,7 @@ jobs: - name: Verify build output working-directory: example/ios run: | - APP=$(find build/Build/Products/Debug-iphonesimulator -maxdepth 1 -name '*.app' -type d | head -1) + APP=$(find build -name '*.app' -type d | head -1) if [ -z "$APP" ]; then echo "::error::No .app bundle found — build may have failed to produce output" exit 1 From b7b1e0c3c2c9b21e4f83a887e9628b3dc0b4cf21 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 12:26:49 -0600 Subject: [PATCH 15/20] fix: commands --- .github/workflows/example_ios_build.yml | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 5906917..fba1feb 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -51,15 +51,30 @@ jobs: - name: Build iOS app (no simulator launch) working-directory: example/ios + shell: bash run: | + set -e WORKSPACE=$(ls -d *.xcworkspace | head -1) SCHEME=$(xcodebuild -list -workspace "$WORKSPACE" -json | jq -r '.workspace.schemes[0]') + if [ -z "$SCHEME" ]; then + echo "::error::Could not determine Xcode scheme" + exit 1 + fi xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" \ -configuration Debug \ -sdk iphonesimulator \ -destination 'generic/platform=iOS Simulator' \ -derivedDataPath build \ - build + build 2>&1 | tee build.log + if [ ${PIPESTATUS[0]} -ne 0 ]; then + echo "::error::xcodebuild exited with non-zero status" + exit 1 + fi + if ! grep -q "BUILD SUCCEEDED" build.log; then + echo "::error::Build did not report BUILD SUCCEEDED — may have been cut off (timeout?) or failed" + exit 1 + fi + echo "Build completed successfully." - name: Verify build output working-directory: example/ios From 8941a667caa7a9d5b16739879e5752daa2ef88c6 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 12:41:17 -0600 Subject: [PATCH 16/20] fix: builds --- .github/workflows/example_ios_build.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index fba1feb..5ef7531 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -60,11 +60,14 @@ jobs: echo "::error::Could not determine Xcode scheme" exit 1 fi + BUILT_PRODUCTS_DIR="$PWD/build/Products/Debug-iphonesimulator" + mkdir -p "$BUILT_PRODUCTS_DIR" xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" \ -configuration Debug \ -sdk iphonesimulator \ -destination 'generic/platform=iOS Simulator' \ -derivedDataPath build \ + CONFIGURATION_BUILD_DIR="$BUILT_PRODUCTS_DIR" \ build 2>&1 | tee build.log if [ ${PIPESTATUS[0]} -ne 0 ]; then echo "::error::xcodebuild exited with non-zero status" @@ -79,9 +82,10 @@ jobs: - name: Verify build output working-directory: example/ios run: | - APP=$(find build -name '*.app' -type d | head -1) + BUILT_PRODUCTS_DIR="build/Products/Debug-iphonesimulator" + APP=$(find "$BUILT_PRODUCTS_DIR" -maxdepth 1 -name '*.app' -type d | head -1) if [ -z "$APP" ]; then - echo "::error::No .app bundle found — build may have failed to produce output" + echo "::error::No .app bundle found in $BUILT_PRODUCTS_DIR" exit 1 fi echo "✅ iOS build verified: $(basename "$APP") produced successfully" \ No newline at end of file From c72c5c4f85d90bcee89f24ad7a678176e91c97ba Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 12:51:19 -0600 Subject: [PATCH 17/20] fix: improve stability --- .github/workflows/example_ios_build.yml | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 5ef7531..5327396 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -14,11 +14,15 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 - # Use latest stable Xcode; consider pinning to specific version (e.g. '16.2') if team needs consistency + # Pin Xcode version for reproducible, stable builds (avoid "latest-stable" drift) - name: Select Xcode version uses: maxim-lobanov/setup-xcode@v1 with: - xcode-version: 'latest-stable' + xcode-version: '16.2' + + - name: Get Xcode version (for cache key) + id: xcode + run: echo "version=$(xcodebuild -version | head -1 | sed 's/Xcode //')" >> $GITHUB_OUTPUT - name: Setup Node.js uses: actions/setup-node@v4 @@ -41,7 +45,7 @@ jobs: id: pods-cache with: path: example/ios/Pods - key: ${{ runner.os }}-pods-${{ hashFiles('example/ios/Podfile', 'example/package-lock.json') }} + key: ${{ runner.os }}-pods-${{ hashFiles('example/ios/Podfile', 'example/package-lock.json') }}-xcode-${{ steps.xcode.outputs.version }} restore-keys: | ${{ runner.os }}-pods- @@ -61,13 +65,17 @@ jobs: exit 1 fi BUILT_PRODUCTS_DIR="$PWD/build/Products/Debug-iphonesimulator" + rm -rf "$BUILT_PRODUCTS_DIR" mkdir -p "$BUILT_PRODUCTS_DIR" + # Sequential build (-jobs 1) and single arch (ONLY_ACTIVE_ARCH=YES) for CI stability xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" \ -configuration Debug \ -sdk iphonesimulator \ -destination 'generic/platform=iOS Simulator' \ -derivedDataPath build \ + -jobs 1 \ CONFIGURATION_BUILD_DIR="$BUILT_PRODUCTS_DIR" \ + ONLY_ACTIVE_ARCH=YES \ build 2>&1 | tee build.log if [ ${PIPESTATUS[0]} -ne 0 ]; then echo "::error::xcodebuild exited with non-zero status" From c2239bbeb0d0bfbcc21706884bdd67e8fc6caca4 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 13:14:06 -0600 Subject: [PATCH 18/20] fix: update xcode version --- .github/workflows/example_ios_build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 5327396..0585035 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -18,7 +18,7 @@ jobs: - name: Select Xcode version uses: maxim-lobanov/setup-xcode@v1 with: - xcode-version: '16.2' + xcode-version: '26.2' - name: Get Xcode version (for cache key) id: xcode From ccb70b73971fdab0ede96a839c7f1e1974fecaef Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 13:25:08 -0600 Subject: [PATCH 19/20] fix: arch --- .github/workflows/example_ios_build.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 0585035..3db2946 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -67,15 +67,17 @@ jobs: BUILT_PRODUCTS_DIR="$PWD/build/Products/Debug-iphonesimulator" rm -rf "$BUILT_PRODUCTS_DIR" mkdir -p "$BUILT_PRODUCTS_DIR" - # Sequential build (-jobs 1) and single arch (ONLY_ACTIVE_ARCH=YES) for CI stability + # Build arm64 only (hosted runners are Apple Silicon; avoid x86_64 to prevent EXConstants/Pods failures) + # Sequential build (-jobs 1) for CI stability xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" \ -configuration Debug \ -sdk iphonesimulator \ -destination 'generic/platform=iOS Simulator' \ -derivedDataPath build \ -jobs 1 \ + ARCHS=arm64 \ + ONLY_ACTIVE_ARCH=NO \ CONFIGURATION_BUILD_DIR="$BUILT_PRODUCTS_DIR" \ - ONLY_ACTIVE_ARCH=YES \ build 2>&1 | tee build.log if [ ${PIPESTATUS[0]} -ne 0 ]; then echo "::error::xcodebuild exited with non-zero status" From e891d33b3110f644352777a25ca5e5793d582462 Mon Sep 17 00:00:00 2001 From: camrun01 Date: Tue, 3 Feb 2026 13:52:56 -0600 Subject: [PATCH 20/20] fix: simplify --- .github/workflows/example_ios_build.yml | 63 +++---------------------- 1 file changed, 7 insertions(+), 56 deletions(-) diff --git a/.github/workflows/example_ios_build.yml b/.github/workflows/example_ios_build.yml index 3db2946..bc0e078 100644 --- a/.github/workflows/example_ios_build.yml +++ b/.github/workflows/example_ios_build.yml @@ -7,23 +7,19 @@ on: jobs: test-ios-build: runs-on: macos-latest + timeout-minutes: 45 permissions: contents: read - + steps: - name: Checkout repository uses: actions/checkout@v4 - # Pin Xcode version for reproducible, stable builds (avoid "latest-stable" drift) - name: Select Xcode version uses: maxim-lobanov/setup-xcode@v1 with: xcode-version: '26.2' - - name: Get Xcode version (for cache key) - id: xcode - run: echo "version=$(xcodebuild -version | head -1 | sed 's/Xcode //')" >> $GITHUB_OUTPUT - - name: Setup Node.js uses: actions/setup-node@v4 with: @@ -36,66 +32,21 @@ jobs: - name: Install dependencies (example app) working-directory: example run: npm ci + - name: Generate native iOS project working-directory: example run: npx expo prebuild --platform ios - name: Cache CocoaPods uses: actions/cache@v4 - id: pods-cache with: path: example/ios/Pods - key: ${{ runner.os }}-pods-${{ hashFiles('example/ios/Podfile', 'example/package-lock.json') }}-xcode-${{ steps.xcode.outputs.version }} - restore-keys: | - ${{ runner.os }}-pods- + key: ${{ runner.os }}-pods-${{ hashFiles('example/ios/Podfile', 'example/package-lock.json') }} - name: Install CocoaPods dependencies working-directory: example/ios run: pod install - - name: Build iOS app (no simulator launch) - working-directory: example/ios - shell: bash - run: | - set -e - WORKSPACE=$(ls -d *.xcworkspace | head -1) - SCHEME=$(xcodebuild -list -workspace "$WORKSPACE" -json | jq -r '.workspace.schemes[0]') - if [ -z "$SCHEME" ]; then - echo "::error::Could not determine Xcode scheme" - exit 1 - fi - BUILT_PRODUCTS_DIR="$PWD/build/Products/Debug-iphonesimulator" - rm -rf "$BUILT_PRODUCTS_DIR" - mkdir -p "$BUILT_PRODUCTS_DIR" - # Build arm64 only (hosted runners are Apple Silicon; avoid x86_64 to prevent EXConstants/Pods failures) - # Sequential build (-jobs 1) for CI stability - xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" \ - -configuration Debug \ - -sdk iphonesimulator \ - -destination 'generic/platform=iOS Simulator' \ - -derivedDataPath build \ - -jobs 1 \ - ARCHS=arm64 \ - ONLY_ACTIVE_ARCH=NO \ - CONFIGURATION_BUILD_DIR="$BUILT_PRODUCTS_DIR" \ - build 2>&1 | tee build.log - if [ ${PIPESTATUS[0]} -ne 0 ]; then - echo "::error::xcodebuild exited with non-zero status" - exit 1 - fi - if ! grep -q "BUILD SUCCEEDED" build.log; then - echo "::error::Build did not report BUILD SUCCEEDED — may have been cut off (timeout?) or failed" - exit 1 - fi - echo "Build completed successfully." - - - name: Verify build output - working-directory: example/ios - run: | - BUILT_PRODUCTS_DIR="build/Products/Debug-iphonesimulator" - APP=$(find "$BUILT_PRODUCTS_DIR" -maxdepth 1 -name '*.app' -type d | head -1) - if [ -z "$APP" ]; then - echo "::error::No .app bundle found in $BUILT_PRODUCTS_DIR" - exit 1 - fi - echo "✅ iOS build verified: $(basename "$APP") produced successfully" \ No newline at end of file + - name: Build iOS app + working-directory: example + run: npm run ios -- --no-install --no-bundler