-
Notifications
You must be signed in to change notification settings - Fork 37
34 lines (31 loc) · 946 Bytes
/
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
name: CI
on:
push:
pull_request:
env:
CARGO_TERM_COLOR: always
# Make sure CI fails on all warnings, including Clippy lints
RUSTFLAGS: "-Dwarnings"
jobs:
build_and_test:
runs-on: ubuntu-latest
strategy:
matrix:
toolchain:
- stable
- beta
- nightly
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- uses: awalsh128/cache-apt-pkgs-action@1850ee53f6e706525805321a3f2f863dcf73c962
with:
packages: mpd
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- run: cargo build --verbose
- run: cargo test --verbose
- if: matrix.toolchain == 'nightly'
run: rustup component add rustfmt && cargo fmt --all -- --check
- if: matrix.toolchain == 'stable'
run: cargo clippy --all-features
- if: matrix.toolchain == 'stable'
run: cargo doc