-
-
Notifications
You must be signed in to change notification settings - Fork 14
99 lines (77 loc) · 2.26 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
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
name: CI
on:
pull_request:
types: [opened, synchronize, reopened]
merge_group:
types: [checks_requested]
push:
branches: [main]
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
read_msrv:
name: Read MSRV
uses: actions-rust-lang/msrv/.github/workflows/[email protected]
build_and_test:
needs: read_msrv
strategy:
fail-fast: false
matrix:
version:
- { name: msrv, version: "${{ needs.read_msrv.outputs.msrv }}" }
- { name: stable, version: stable }
name: Test / ${{ matrix.version.name }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup mold linker
uses: rui314/setup-mold@v1
- name: Install Rust (${{ matrix.version.name }})
uses: actions-rust-lang/[email protected]
with:
toolchain: ${{ matrix.version.version }}
- name: Install just, cargo-hack, cargo-nextest, cargo-ci-cache-clean
uses: taiki-e/[email protected]
with:
tool: just,cargo-hack,cargo-nextest,cargo-ci-cache-clean
- name: workaround MSRV issues
if: matrix.version.name == 'msrv'
run: just downgrade-for-msrv
- name: tests
timeout-minutes: 60
run: just test
- name: CI cache clean
run: cargo-ci-cache-clean
rustdoc:
name: Docuemntation Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust (nightly)
uses: actions-rust-lang/[email protected]
with:
toolchain: nightly
- name: Install just
uses: taiki-e/[email protected]
with:
tool: just
- name: doc tests
run: just test-docs
features:
name: Feature Combinations
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust (stable)
uses: actions-rust-lang/[email protected]
- name: Install cargo-hack
uses: taiki-e/[email protected]
with:
tool: cargo-hack
- name: doc tests
run: |
cargo hack --each-feature check
cargo hack --each-feature check --all-targets