-
Notifications
You must be signed in to change notification settings - Fork 32
36 lines (35 loc) · 962 Bytes
/
build-test.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
name: Build Test
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
env:
AUTH_SERVER_IP: ${{ secrets.AUTH_SERVER_IP }}
steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }}
- name: Setup rust toolchain
run: rustup show
- name: cargo build
uses: actions-rs/cargo@v1
with:
command: build
args: --release --all-targets
- name: cargo fmt
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- name: cargo clippy
uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
# args: --all-features