name: ios on: push: branches: [main] workflow_dispatch: jobs: ios-build: runs-on: macos-14 steps: - uses: actions/checkout@v4 - name: Gradle & Konan cache (warm build across runs) uses: actions/cache@v4 with: path: | ~/.gradle/caches ~/.gradle/wrapper ~/.konan key: ios-${{ runner.os }}-${{ hashFiles('gradle/libs.versions.toml', 'gradle/wrapper/gradle-wrapper.properties', '**/*.gradle.kts') }} restore-keys: | ios-${{ runner.os }}- - name: JDK 21 uses: actions/setup-java@v4 with: distribution: temurin java-version: '21' - name: Compile iOS targets run: | chmod +x gradlew ./gradlew :modules:orgflow-domain:compileKotlinIosArm64 \ :modules:orgflow-domain:compileKotlinIosSimulatorArm64 \ :modules:orgflow-domain:compileKotlinIosX64 \ :modules:orgflow-domain:linkDebugFrameworkIosArm64 \ :modules:orgflow-domain:linkDebugFrameworkIosSimulatorArm64 \ --no-daemon - name: Simulator tests run: ./gradlew :modules:orgflow-domain:iosSimulatorArm64Test --no-daemon - name: Collect frameworks if: always() run: | mkdir -p out # frameworks live in build/bin//Framework, klibs in # build/classes/kotlin//*/ (compile tasks only emit klibs) find modules/orgflow-domain/build \( -name "*.framework" -o -name "*.klib" \) | while read f; do cp -r "$f" out/ 2>/dev/null || true done ls out || true - uses: actions/upload-artifact@v4 with: name: kukuri-ios path: out if-no-files-found: error