-
Notifications
You must be signed in to change notification settings - Fork 2
73 lines (73 loc) · 2.03 KB
/
lint-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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
name: Lint Builds
'on':
push:
branches:
- '**'
paths:
# It would be nice if I could specify this per-job, but I'm not making a whole new file just to avoid running
# clang for web-only changes.
- src/**
- wasm/*
- .clang-format
- .github/workflows/lint-build.yml
workflow_dispatch: ~
jobs:
build-native-mac:
runs-on: macos-latest
strategy:
matrix:
arch:
- x86_64
- aarch64
name: Verify C++ Build with clang on ${{ matrix.arch }}
steps:
- uses: actions/checkout@v4
- name: Invoke clang
shell: bash
run: >+
clang++ -DVERSION=0.0.0 -DNDEBUG -WCL4 -Wnon-gcc -Wimplicit-fallthrough -Werror -std=c++14 -o /dev/null
-target "$(clang -dumpmachine | sed -E 's/^\w+-/${{ matrix.arch }}-/')" src/*.cpp
build-native-windows:
runs-on: windows-latest
strategy:
matrix:
include:
- cmd_arch: amd64
disp_arch: x86_64
- cmd_arch: amd64_x86
disp_arch: x86
- cmd_arch: amd64_arm64
disp_arch: arm64
name: Verify C++ Build with MSVC on ${{ matrix.disp_arch }}
steps:
- uses: actions/checkout@v4
- uses: ilammy/msvc-dev-cmd@v1.13.0
with:
arch: ${{ matrix.cmd_arch }}
- name: Invoke MSVC
shell: pwsh
run: |
cl .\src\*.cpp /EHsc /DVERSION=0.0.0 /DNDEBUG /std:c++20 /MTd /analyze /W4 /WX /we5219
lint-npm:
runs-on: ubuntu-latest
name: Lint with JS Tools
steps:
- uses: actions/checkout@v4
- name: npm lint
shell: bash
run: |
cd wasm
npm ci --no-fund
npm run lint
verify-wasm-build:
runs-on: ubuntu-latest
name: Verify wasm build
steps:
- uses: actions/checkout@v4
- uses: numworks/setup-emscripten@bbc4f5e15974bc13e69fdadecfd1858ecb1c4dbb
- name: Run build script
shell: bash
run: |
cd wasm
npm ci --omit dev --no-fund
./build_wasm.sh lint