fix ci #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://github.com/Kotlin/multiplatform-library-template/blob/main/.github/workflows/gradle.yml | |
# https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle | |
name: CI | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["main"] | |
workflow_call: | |
permissions: | |
contents: read | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- cmd: "./gradlew :kmp-webrtc:testDebugUnitTest" | |
os: macos-latest | |
dep: "brew update && brew install unzip" | |
- cmd: "./gradlew :example:androidApp:assembleDebug" | |
os: macos-latest | |
dep: "brew update && brew install unzip" | |
- cmd: "cd example/iosApp && xcodegen && pod install && xcodebuild -workspace iosApp.xcworkspace -scheme iosApp -sdk iphonesimulator -configuration Debug" | |
os: macos-latest | |
dep: "brew update && brew install cocoapods xcodegen unzip" | |
runs-on: ${{ matrix.os }} | |
permissions: | |
pull-requests: write | |
contents: write | |
id-token: write | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: "recursive" | |
- uses: actions/setup-java@v4 | |
with: | |
java-version: "17" | |
distribution: "temurin" | |
cache: "gradle" | |
- uses: gradle/actions/setup-gradle@v3 | |
- uses: suisei-cn/[email protected] | |
id: download_libs # Remember to give an ID if you need the output filename | |
name: Download libs.zip | |
with: | |
url: "https://github.com/HackWebRTC/kmp-webrtc/releases/latest/download/libs.zip" | |
target: ./ | |
- name: Extract libs | |
run: | | |
unzip libs.zip | |
- if: ${{ matrix.dep }} | |
run: ${{ matrix.dep }} | |
- if: ${{ matrix.os == 'windows-latest' }} | |
shell: cmd | |
run: ${{ matrix.cmd }} | |
- if: ${{ matrix.os != 'windows-latest' }} | |
run: ${{ matrix.cmd }} |