Skip to content

Commit 5eee6a5

Browse files
committed
Split github action jobs
1 parent 6395622 commit 5eee6a5

1 file changed

Lines changed: 19 additions & 14 deletions

File tree

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,32 @@
1-
on: [ push ]
1+
on:
2+
push:
3+
branches:
4+
- master
25

3-
name: build
6+
name: Check buddy
47

58
jobs:
69
check:
7-
name: Check Buddy
810
runs-on: ubuntu-latest
911
steps:
1012
- uses: actions/checkout@v3
11-
- name: Install latest stable
12-
uses: actions-rs/toolchain@v1
13+
- uses: actions-rs/toolchain@v1
1314
with:
14-
toolchain: stable
15-
override: true
1615
components: rustfmt, clippy
17-
18-
- name: Run cargo check
19-
uses: actions-rs/cargo@v1
20-
with:
21-
command: check
22-
16+
- uses: Swatinem/rust-cache@v2
17+
- name: Check
18+
run: cargo clippy --workspace --all-targets --all-features -- -D warnings
19+
- name: rustfmt
20+
run: cargo fmt --all --check
21+
test:
22+
needs: check
23+
runs-on: ubuntu-latest
24+
steps:
25+
- uses: actions/checkout@v3
26+
- uses: actions-rs/toolchain@v1
27+
- uses: Swatinem/rust-cache@v2
2328
- name: Run cargo test
2429
uses: actions-rs/cargo@v1
2530
with:
2631
command: test
27-
args: --all
32+
args: --workspace --all

0 commit comments

Comments
 (0)