Skip to content

Commit 2445597

Browse files
Merge pull request #6 from mockersf/basic-ci
basic CI
2 parents 87a54b6 + 9dcbdc0 commit 2445597

File tree

1 file changed

+61
-0
lines changed

1 file changed

+61
-0
lines changed

.github/workflows/ci.yml

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
pull_request:
6+
7+
jobs:
8+
format:
9+
name: Format
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
14+
- uses: dtolnay/rust-toolchain@stable
15+
with:
16+
components: rustfmt
17+
18+
- name: Check format
19+
run: |
20+
cargo fmt --all -- --check
21+
22+
clippy:
23+
name: Clippy
24+
runs-on: ubuntu-latest
25+
steps:
26+
- name: Checkout repository
27+
uses: actions/checkout@v4
28+
29+
- uses: dtolnay/rust-toolchain@stable
30+
with:
31+
components: clippy
32+
33+
- name: Run clippy
34+
run: |
35+
cargo clippy -- -D warnings
36+
37+
check:
38+
name: Check
39+
runs-on: ubuntu-latest
40+
steps:
41+
- name: Checkout repository
42+
uses: actions/checkout@v4
43+
44+
- uses: dtolnay/rust-toolchain@stable
45+
46+
- name: Check
47+
run: |
48+
cargo check
49+
50+
test:
51+
name: Test
52+
runs-on: ubuntu-latest
53+
steps:
54+
- name: Checkout repository
55+
uses: actions/checkout@v4
56+
57+
- uses: dtolnay/rust-toolchain@stable
58+
59+
- name: Test
60+
run: |
61+
cargo test

0 commit comments

Comments
 (0)