-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (44 loc) · 1.12 KB
/
ci.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
name: CI
on:
push:
branches:
- main
pull_request:
env:
# The NAME makes it easier to copy/paste snippets from other CI configs
NAME: icemelter
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Format
run: cargo fmt && git diff --exit-code
- name: Deps
run: |
rustup update
rustup component add clippy
- uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab
- name: Lint
run: cargo clippy -- --deny warnings
static:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Deps
run: |
sudo apt-get install -y musl-tools
rustup target add x86_64-unknown-linux-musl
- uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab
- run: |
cargo build \
--locked \
--release \
--target=x86_64-unknown-linux-musl
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab
- run: cargo test --locked --no-run
- run: cargo test