-
Notifications
You must be signed in to change notification settings - Fork 0
87 lines (78 loc) · 2.11 KB
/
rust.yaml
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
name: Rust
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
env:
CARGO_TERM_COLOR: always
jobs:
codestyle:
runs-on: ubuntu-latest
steps:
- name: Set up Rust
uses: hecrj/setup-rust-action@v2
with:
components: rustfmt
- uses: actions/checkout@v4
- run: cargo fmt --check
lint:
runs-on: ubuntu-latest
steps:
- name: Set up Rust
uses: hecrj/setup-rust-action@v2
with:
components: clippy
- uses: actions/checkout@v4
- run: cargo clippy --all-targets --all-features -- -D warnings
compile:
runs-on: ubuntu-latest
steps:
- name: Set up Rust
uses: hecrj/setup-rust-action@v2
- uses: actions/checkout@master
- run: cargo check --all-targets --all-features
docs:
runs-on: ubuntu-latest
env:
RUSTDOCFLAGS: "-Dwarnings"
steps:
- name: Set up Rust
uses: hecrj/setup-rust-action@v2
- uses: actions/checkout@master
- run: cargo doc --document-private-items --no-deps --workspace --all-features
test:
runs-on: ubuntu-latest
steps:
- name: Setup Rust
uses: hecrj/setup-rust-action@v2
with:
rust-version: stable
- name: Checkout
uses: actions/checkout@v4
- name: Test
run: cargo test --all-features
test-coverage:
runs-on: ubuntu-latest
steps:
- name: Setup Rust
uses: hecrj/setup-rust-action@v2
with:
rust-version: stable
- name: Install Tarpaulin
uses: actions-rs/[email protected]
with:
crate: cargo-tarpaulin
version: 0.30.0
use-tool-cache: true
- name: Checkout
uses: actions/checkout@v4
- name: Coverage
run: cargo tarpaulin --workspace --follow-exec --engine Llvm -o Lcov --output-dir ./coverage
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
files: ./coverage/lcov.info
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
slug: takaebato/sql-insight