-
Notifications
You must be signed in to change notification settings - Fork 7
41 lines (39 loc) · 1.14 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
name: Build & Test
on:
push:
branches:
- master
pull_request:
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- toolchain: stable
- toolchain: 1.63.0
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Rust
uses: dtolnay/rust-toolchain@v1
with:
toolchain: ${{ matrix.rust.toolchain }}
components: clippy, rustfmt
- name: Pin dependencies for MSRV
if: matrix.rust.toolchain == '1.63.0'
run: |
cargo update -p zstd-sys --precise "2.0.8+zstd.1.5.5"
cargo update -p time --precise "0.3.20"
cargo update -p home --precise "0.5.5"
cargo update -p tokio --precise "1.37.0"
- name: Lint all targets
run: cargo clippy --all-targets
- name: Format
run: cargo fmt -- --check
- name: Build with default features
run: cargo build --verbose
- name: Check release build on Rust ${{ matrix.rust.toolchain }}
run: cargo check --release --verbose --color always
- name: Test
run: cargo test --verbose