From 01d60d2d49ccf167d076c41df8b9f21370cdfc07 Mon Sep 17 00:00:00 2001 From: liyi Date: Mon, 22 Sep 2025 18:25:50 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=B5=8B=E8=AF=95ci?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/ci.yml | 51 ++++++++++++++++++++++++++++++----------- 1 file changed, 38 insertions(+), 13 deletions(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 095220b4..01fb7e3c 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -1,19 +1,44 @@ -name: Gitea Actions Demo -run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀 -on: [push] +name: Flutter CI - Build iOS & Android + +on: + push: + branches: + - develop_sky jobs: - Explore-Gitea-Actions: + build: + name: Build Flutter App runs-on: sky + steps: - - run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event." - - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!" - - run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}." - - name: Check out repository code + - name: Checkout Code uses: actions/checkout@v4 - - run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner." - - run: echo "🖥️ The workflow is now ready to test your code on the runner." - - name: List files in the repository + + - name: Setup Flutter run: | - ls ${{ gitea.workspace }} - - run: echo "🍏 This job's status is ${{ job.status }}." \ No newline at end of file + flutter --version + flutter pub get + + - name: Run Tests + run: flutter test + + - name: Analyze Code + run: flutter analyze + + - name: Build iOS IPA + run: flutter build ipa --release --export-method ad-hoc + + - name: Build Android APK + run: flutter build apk --release + + - name: Build Android AAB + run: flutter build appbundle --release + + - name: Upload Artifacts + uses: actions/upload-artifact@v4 + with: + name: flutter-builds + path: | + build/app/outputs/flutter-apk/ + build/app/outputs/bundle/ + build/ios/ipa/ \ No newline at end of file