ci: reset stale CocoaPods trunk repo on Xcode Cloud workers

This commit is contained in:
Evan Kaloudis
2026-06-20 12:26:06 -04:00
parent b8ec266bfa
commit 2f7b74795a
+12
View File
@@ -16,6 +16,18 @@ brew install yarn
# Install dependencies
echo "===== Running yarn install ====="
yarn install
# Reset stale CocoaPods spec-repo state from cached Xcode Cloud worker
# images. The Homebrew CocoaPods 1.16+ wants the trunk source registered
# as a CDN, but a pre-existing `~/.cocoapods/repos/trunk` from older
# installs makes `pod install` abort with:
# [!] Unable to add a source with url `https://cdn.cocoapods.org/`
# named `trunk`.
# Wiping the dir and explicitly registering the CDN source up front
# makes the install path deterministic on every run.
rm -rf "$HOME/.cocoapods/repos/trunk" 2>/dev/null || true
pod repo add-cdn trunk https://cdn.cocoapods.org/ 2>/dev/null || true
echo "===== Running pod install ====="
cd ios
pod install