-
Notifications
You must be signed in to change notification settings - Fork 104
58 lines (49 loc) · 1.34 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: Build
on:
push:
branches: [main, zig-master]
pull_request:
branches: [main]
schedule:
- cron: "0 0 * * *"
jobs:
build:
runs-on: ${{ matrix.os }}
continue-on-error: true
strategy:
matrix:
os: [
ubuntu-latest,
windows-latest,
macos-latest,
]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Zig
uses: mlugg/setup-zig@v1
with:
version: 0.13.0
- name: Build
run: zig build -Doptimize=ReleaseSmall
- name: Unit Test Ports
run: |
cd port/raspberrypi/rp2xxx
zig build test
- name: Build Website
run: zig build
working-directory: website
- name: Dry run packaging
if: ${{ matrix.os == 'macos-latest' }}
run: |
MICROZIG_VERSION=$(zig build package -- get-version)
echo microzig version: $MICROZIG_VERSION
zig build package -- http://localhost:8000
python3 -m http.server 8000 --directory boxzer-out &
sleep 1
cd tools/package-test
zig fetch --save=microzig http://localhost:8000/${MICROZIG_VERSION}/microzig.tar.gz
zig build -Doptimize=ReleaseSmall
# zig build run-port-tests
# clean up server
jobs -p | xargs kill