-
Notifications
You must be signed in to change notification settings - Fork 2
59 lines (48 loc) · 1.41 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
name: CI
on:
push:
branches:
- '*'
pull_request:
branches:
- master
env:
CARGO_TERM_COLOR: always
jobs:
checks:
runs-on: ubuntu-latest
# Only use stable for now.
strategy:
matrix:
toolchain:
- stable
#- beta
#- nightly
steps:
- uses: actions/checkout@v4
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- name: Verify project manifest
run: cargo verify-project --verbose
# - name: Check build
# run: cargo check --verbose --all-targets --all-features
# - name: Build and run tests
# run: cargo test --verbose --all-targets --all-features
- name: Check correct rustfmt formatting
# HACK: pass all configuration items via CLI to circumvent unstability restriction.
run: >
cargo fmt --verbose --all --check
-- --config-path=/dev/null --config=$(
cat rustfmt.toml
\| sed -E 's/\#.*$//g'
\| sed '/^$/d'
\| sed 's/ //g'
\| sed -Ez 's/(\r)?\n/,/g'
\| sed 's/,$//'
\| sed 's/"//g'
)
# - name: Check clippy warnings
# run: cargo clippy --verbose --all-targets --all-features -- --deny warnings
# - name: Build documentation
# run: cargo doc --verbose --all-features --no-deps --document-private-items
# env:
# RUSTDOCFLAGS: "-Dwarnings"