11name : Swift
2-
32on : [push]
4-
53jobs :
6- build :
7- name : Build
4+
5+ macos :
6+ name : macOS
7+ runs-on : macos-15
8+ strategy :
9+ matrix :
10+ config : ["debug", "release"]
11+ options : ["", "SWIFT_BUILD_DYNAMIC_LIBRARY=1"]
12+ steps :
13+ - name : Checkout
14+ uses : actions/checkout@v4
15+ - name : Swift Version
16+ run : swift --version
17+ - name : Build
18+ run : ${{ matrix.options }} swift build -c ${{ matrix.config }}
19+ - name : Test
20+ run : ${{ matrix.options }} swift test -c ${{ matrix.config }}
21+
22+ linux :
23+ name : Linux
824 strategy :
925 matrix :
10- swift : [5.6.3, 5.7]
11- os : [ubuntu-20.04]
12- runs-on : ${{ matrix.os }}
26+ container : ["swift:6.0.3", "swift:6.1.2"]
27+ config : ["debug", "release"]
28+ options : ["", "SWIFT_BUILD_DYNAMIC_LIBRARY=1"]
29+ runs-on : ubuntu-latest
30+ container : ${{ matrix.container }}-jammy
1331 steps :
14- - name : Install Swift
15- uses : slashmo/install-swift@v0.3.0
16- with :
17- version : ${{ matrix.swift }}
1832 - name : Checkout
19- uses : actions/checkout@v2
33+ uses : actions/checkout@v4
2034 - name : Swift Version
2135 run : swift --version
22- - name : Build (Debug)
23- run : swift build -c debug
24- - name : Build (Release)
25- run : swift build -c release
26- - name : Test (Debug)
27- run : swift test --configuration debug
28- - name : Test (Release)
29- run : swift test --configuration release -Xswiftc -enable-testing
36+ - name : Build
37+ run : ${{ matrix.options }} swift build -c ${{ matrix.config }}
38+ - name : Test
39+ run : ${{ matrix.options }} swift test -c ${{ matrix.config }}
40+
41+ android :
42+ name : Android
43+ strategy :
44+ fail-fast : false
45+ matrix :
46+ swift : ['6.1', 'nightly-6.2']
47+ arch : ["aarch64", "x86_64"]
48+ runs-on : macos-15
49+ timeout-minutes : 30
50+ steps :
51+ - uses : actions/checkout@v4
52+ - name : " Build Swift Package for Android"
53+ run : |
54+ brew install skiptools/skip/skip || (brew update && brew install skiptools/skip/skip)
55+ skip android sdk install --version ${{ matrix.swift }}
56+ ANDROID_NDK_ROOT="" skip android build --arch ${{ matrix.arch }}
0 commit comments