-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (39 loc) · 1.06 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
name: Build
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
env:
CARGO_TERM_COLOR: always
jobs:
build:
name: Build on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- os: ubuntu-latest
artifact_name: baker
asset_name: baker-linux-amd64
- os: windows-latest
artifact_name: baker.exe
asset_name: baker-windows-amd64.exe
- os: macos-latest
artifact_name: baker
asset_name: baker-macos-amd64
steps:
- uses: actions/checkout@v3
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
- name: Check formatting
run: cargo fmt --all -- --check
- name: Run clippy
run: cargo clippy -- -D warnings
- name: Build Release
run: cargo build --verbose --release
- name: Run tests
run: cargo test --verbose