From 4fa0d891bba8738120759058c27b65e2d5e166fa Mon Sep 17 00:00:00 2001 From: millianlmx Date: Sat, 27 Jun 2026 22:20:18 +0000 Subject: [PATCH] fix(ci): replace Firebase OTA with USB direct deploy --- .gitea/workflows/pr-iphone-deploy.yml | 47 +++++++---------------- tabatago-swift/Config/exportOptions.plist | 14 ------- 2 files changed, 14 insertions(+), 47 deletions(-) delete mode 100644 tabatago-swift/Config/exportOptions.plist diff --git a/.gitea/workflows/pr-iphone-deploy.yml b/.gitea/workflows/pr-iphone-deploy.yml index 3e3bd0c..7ae783b 100644 --- a/.gitea/workflows/pr-iphone-deploy.yml +++ b/.gitea/workflows/pr-iphone-deploy.yml @@ -1,8 +1,8 @@ # ============================================================================= -# TabataGo — PR → Build → Archive → Firebase OTA → Wait LGTM → Merge +# TabataGo — PR → Build → USB Direct Deploy → Wait LGTM → Merge # ============================================================================= -name: PR → Build → Firebase OTA → LGTM +name: PR → Build → USB Deploy → LGTM on: pull_request: @@ -16,14 +16,14 @@ permissions: jobs: build-deploy: - name: Build & Deploy to Firebase OTA + name: Build & Deploy to iPhone via USB runs-on: macos timeout-minutes: 20 steps: - name: Checkout run: | - git clone --depth 1 -b ${{ github.head_ref }} https://x-access-token:${PR_TOKEN}@gitea.1000co.fr/${REPO}.git . + git clone --depth 1 -b ${{ github.head_ref }} https://x-access-token:${PR_TOKEN}@gitea.1000co.fr/${{ github.repository }}.git . env: PR_TOKEN: ${{ secrets.PR_API_TOKEN }} REPO: ${{ github.repository }} @@ -67,10 +67,9 @@ jobs: echo "✅ Caches nettoyés" - - name: Install tools (xcodegen, node, firebase) + - name: Install tools (xcodegen, node, ios-deploy) run: | - brew install xcodegen node || true - npm install -g firebase-tools + brew install xcodegen node ios-deploy || true - name: Generate Xcode project run: | @@ -84,15 +83,13 @@ jobs: -project TabataGo.xcodeproj \ -scmProvider system - - name: Archive app + - name: Build app run: | cd tabatago-swift - xcodebuild -list - xcodebuild archive \ + xcodebuild build \ -project TabataGo.xcodeproj \ -scheme TabataGo \ - -configuration Release \ - -archivePath ../build/TabataGo.xcarchive \ + -configuration Debug \ -allowProvisioningUpdates \ -skipPackagePluginValidation \ -derivedDataPath ../build/derived \ @@ -102,27 +99,11 @@ jobs: CODE_SIGN_STYLE=Automatic \ DEVELOPMENT_TEAM=2MJF39L8VY - - name: Export IPA (Ad Hoc) + - name: Install to iPhone run: | - cd tabatago-swift - mkdir -p build - xcodebuild -exportArchive \ - -archivePath ../build/TabataGo.xcarchive \ - -exportPath build \ - -exportOptionsPlist Config/exportOptions.plist \ - -allowProvisioningUpdates - - - name: Deploy to Firebase - env: - FIREBASE_APP_ID: ${{ secrets.FIREBASE_APP_ID }} - FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} - run: | - npx firebase appdistribution:distribute tabatago-swift/build/TabataGo.ipa \ - --app "${FIREBASE_APP_ID}" \ - --groups "millian-test" \ - --project tabatago-19a80 \ - --token "${FIREBASE_TOKEN}" \ - --release-notes "PR: ${{ github.event.pull_request.title }}" + APP=$(find ../build/derived -name 'TabataGo.app' -type d | head -1) + echo "📱 Installing $APP to iPhone..." + ios-deploy --bundle "$APP" --id 00008120-000925CE3672201E --justlaunch - name: Post "Ready to test" comment env: @@ -134,7 +115,7 @@ jobs: curl -s -X POST \ -H "Authorization: token ${GT_TOKEN}" \ -H "Content-Type: application/json" \ - -d "{\"body\":\"## 📱 Prêt à tester !\\n\\nL\'app est déployée via Firebase.\\n\\n- Teste les changements\\n- Reply **LGTM** pour merger\\n- Reply **KO** pour bloquer\"}" \ + -d "{\"body\":\"## 📱 Prêt à tester !\\n\\nL'app est déployée sur l'iPhone (USB).\\n\\n- Teste les changements\\n- Reply **LGTM** pour merger\\n- Reply **KO** pour bloquer\"}" \ "${GITEA_URL}/api/v1/repos/${REPO}/issues/${PR}/comments" wait-approval: diff --git a/tabatago-swift/Config/exportOptions.plist b/tabatago-swift/Config/exportOptions.plist deleted file mode 100644 index 9da1850..0000000 --- a/tabatago-swift/Config/exportOptions.plist +++ /dev/null @@ -1,14 +0,0 @@ - - - - - method - ad-hoc - teamID - 2MJF39L8VY - compileBitcode - - signingStyle - automatic - -