-
Notifications
You must be signed in to change notification settings - Fork 19
50 lines (46 loc) · 1.25 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
name: Build and Test
on:
push:
branches: [ main, "maintenance/**" ]
pull_request:
branches: [ "**" ]
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
jobs:
test:
name: Cargo test
runs-on: ubuntu-22.04
steps:
- name: Maximize build space
uses: easimon/maximize-build-space@master # https://github.com/easimon/maximize-build-space
with:
root-reserve-mb: 4096
temp-reserve-mb: 1024
swap-size-mb: 8192
remove-dotnet: "true"
remove-android: "true"
remove-haskell: "true"
- uses: actions/checkout@v3
with:
submodules: "true"
- name: Install build dependencies
run: |
sudo apt-get update
sudo apt-get -y install llvm clang protobuf-compiler
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
default: true
toolchain: 1.72.0
target: wasm32-unknown-unknown
- name: Cargo test
uses: actions-rs/cargo@v1
with:
command: test
args: --workspace
- name: Show disk usage
if: always()
run: df -h