CI/CD Pipeline Integration: iOS + Android stages with Gitea-native syntax #11
+42
-7
@@ -212,15 +212,50 @@ jobs:
|
|||||||
name: Build iOS
|
name: Build iOS
|
||||||
runs-on: [self-hosted, macos]
|
runs-on: [self-hosted, macos]
|
||||||
needs: [lint, test]
|
needs: [lint, test]
|
||||||
if: always()
|
|
||||||
steps:
|
steps:
|
||||||
|
|
|||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Check iOS build feasibility
|
- name: Setup Java 17
|
||||||
run: |
|
run: |
|
||||||
OS=$(uname -s)
|
set -e
|
||||||
echo "INFO: iOS builds require macOS host with Xcode."
|
brew install openjdk@17 || true
|
||||||
echo "Detected OS: $OS"
|
export JAVA_HOME="/usr/local/opt/openjdk@17"
|
||||||
echo "Skipping iOS build - it will succeed as a no-op."
|
export PATH="$JAVA_HOME/bin:$PATH"
|
||||||
echo "To enable iOS builds, configure a native macOS runner with Xcode."
|
java -version
|
||||||
|
|
||||||
|
- name: Setup Flutter
|
||||||
|
run: |
|
||||||
|
set -e
|
||||||
|
curl -fsSL "https://storage.googleapis.com/flutter_infra_release/releases/stable/macos/flutter_macos_${{ env.FLUTTER_VERSION }}-stable.tar.xz" \
|
||||||
|
-o /tmp/flutter.tar.xz
|
||||||
|
tar -xf /tmp/flutter.tar.xz -C "$PWD"
|
||||||
|
export PATH="$PWD/flutter/bin:$PATH"
|
||||||
|
flutter --version
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
export PATH="$PWD/flutter/bin:$PATH"
|
||||||
|
flutter pub get
|
||||||
|
|
||||||
|
- name: Generate stubs (lint gate support)
|
||||||
|
run: |
|
||||||
|
export PATH="$PWD/flutter/bin:$PATH"
|
||||||
|
python3 ci_stub_gen.py
|
||||||
|
|
||||||
|
- name: Run whitelabel build script
|
||||||
|
if: hashFiles('theme.json') != ''
|
||||||
|
run: |
|
||||||
|
export PATH="$PWD/flutter/bin:$PATH"
|
||||||
|
python3 build_whitelabel.py
|
||||||
|
|
||||||
|
- name: Build iOS (release, no-codesign)
|
||||||
|
run: |
|
||||||
|
export JAVA_HOME="/usr/local/opt/openjdk@17"
|
||||||
|
export PATH="$PWD/flutter/bin:$PATH"
|
||||||
|
flutter build ios --release --no-codesign
|
||||||
|
|
||||||
|
- name: List build outputs
|
||||||
|
run: |
|
||||||
|
echo "=== iOS build output ==="
|
||||||
|
ls -lh build/ios/iphoneos/ || true
|
||||||
Reference in new issue
Block a user
It's impossible for this (which requires ios) to run-on ubuntu.