-
Notifications
You must be signed in to change notification settings - Fork 3
58 lines (53 loc) · 1.27 KB
/
rust.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
name: Rust
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
env:
CARGO_TERM_COLOR: always
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- name: Setup Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
profile: minimal
components: clippy
- name: Lint
uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --all-features
- name: Run tests
if: ${{ runner.os == 'Linux' }}
uses: actions-rs/tarpaulin@v0.1
with:
version: 0.22.0
- name: Run tests (Windows)
if: ${{ runner.os == 'Windows' }}
uses: actions-rs/cargo@v1
with:
command: test
- name: Upload to codecov
if: ${{ runner.os == 'Linux' }}
uses: codecov/codecov-action@v2
- name: Run Benchmarks
uses: actions-rs/cargo@v1
with:
command: bench
- name: Publish artifact
uses: actions/upload-artifact@v2.2.4
with:
name: trackie
path: |
target/release/trackie
target/release/trackie.exe
if-no-files-found: error