-
Notifications
You must be signed in to change notification settings - Fork 3
101 lines (98 loc) · 2.76 KB
/
ci.yml
File metadata and controls
101 lines (98 loc) · 2.76 KB
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
name: CI
on:
push:
branches: [main, master]
pull_request:
env:
CARGO_TERM_COLOR: always
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- freebsd_version: "14.4"
rust_version: "stable"
- freebsd_version: "15.0"
rust_version: "nightly"
name: FreeBSD ${{ matrix.freebsd_version }} ${{ matrix.rust_version }}
steps:
- uses: actions/checkout@v6
- name: Start VM
uses: vmactions/freebsd-vm@v1
with:
release: ${{ matrix.freebsd_version }}
usesh: true
- name: Install dependencies
shell: freebsd {0}
run: |
pkg install -y curl
fetch https://sh.rustup.rs -o rustup.sh
sh rustup.sh -y --profile=minimal --default-toolchain ${{ matrix.rust_version }}
- name: Test
shell: freebsd {0}
run: |
. $HOME/.cargo/env
cargo test -- --nocapture
- name: Doc
shell: freebsd {0}
run: |
. $HOME/.cargo/env
cargo doc --no-deps
- name: Clippy
if: matrix.rust_version == 'nightly'
shell: freebsd {0}
run: |
. $HOME/.cargo/env
rustup component add clippy
cargo clippy --all-features --all-targets -- -D warnings
- name: Audit
if: matrix.rust_version == 'nightly'
shell: freebsd {0}
run: |
. $HOME/.cargo/env
pkg install -y cargo-audit
cargo audit
- name: Minver
if: matrix.rust_version == 'nightly'
shell: freebsd {0}
run: |
. $HOME/.cargo/env
cargo update -Zdirect-minimal-versions
cargo check --all-targets
cargo doc --no-deps
- name: Fmt
if: matrix.rust_version == 'nightly'
shell: freebsd {0}
run: |
. $HOME/.cargo/env
rustup component add rustfmt
cargo fmt --all -- --check --color=never
msrv:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- freebsd_version: "14.4"
rust_version: "1.71.0"
name: FreeBSD ${{ matrix.freebsd_version }} ${{ matrix.rust_version }}
steps:
- uses: actions/checkout@v6
- name: Start VM
uses: vmactions/freebsd-vm@v1
with:
release: ${{ matrix.freebsd_version }}
usesh: true
- name: Install dependencies
shell: freebsd {0}
run: |
pkg install -y curl
fetch https://sh.rustup.rs -o rustup.sh
sh rustup.sh -y --profile=minimal --default-toolchain ${{ matrix.rust_version }}
- name: Test
shell: freebsd {0}
run: |
. $HOME/.cargo/env
cargo check