File tree Expand file tree Collapse file tree 1 file changed +18
-40
lines changed Expand file tree Collapse file tree 1 file changed +18
-40
lines changed Original file line number Diff line number Diff line change 1- name : Build and Test
1+ name : CI
2+
23on :
34 push :
45 branches : [main]
@@ -11,49 +12,26 @@ jobs:
1112 fail-fast : false
1213 matrix :
1314 os : [windows-latest, ubuntu-latest, macos-latest]
14- target : [
15- native,
16- x86_64-linux-gnu,
17- x86_64-linux-musl,
18- x86_64-windows,
19- aarch64-macos,
20- aarch64-linux-gnu,
21- aarch64-linux-musl
22- # TODO: bsd
23- ]
24- optimize : [
25- Debug,
26- ReleaseSafe,
27- ReleaseFast,
28- ReleaseSmall
29- ]
3015 runs-on : ${{ matrix.os }}
3116 steps :
32- - uses : actions/checkout@v2
33- with :
34- submodules : recursive
17+ uses : actions/checkout@v4
3518
3619 - name : Setup Zig
37- 38- with :
39- version : 0.15.1
40- - name : Build
41- run : zig build -Dtarget=${{ matrix.target }} -Doptimize=${{ matrix.optimize }}
42- test :
43- strategy :
44- fail-fast : false
45- matrix :
46- os : [windows-latest, ubuntu-latest, macos-latest]
47- runs-on : ${{ matrix.os }}
48- steps :
49- - uses : actions/checkout@v2
50- with :
51- submodules : recursive
20+ uses : mlugg/setup-zig@v2
5221
53- - name : Setup Zig
54- 55- with :
56- version : 0.15.1
22+ - name : Check Formatting
23+ run : zig fmt --ast-check --check .
24+
25+ - name : Build
26+ run : zig build --summary all
5727
5828 - name : Test
59- run : zig build test
29+ run : zig build test --summary all
30+
31+ - name : Cross Compile
32+ if : matrix.os == 'ubuntu-latest'
33+ uses : |
34+ zig build -Dtarget=native-linux-gnu
35+ zig build -Dtarget=native-linux-musl
36+ zig build -Dtarget=native-freebsd
37+ zig build -Dtarget=native-netbsd
You can’t perform that action at this time.
0 commit comments