aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows')
-rw-r--r--.github/workflows/pull_request.yml41
-rw-r--r--.github/workflows/push.yml (renamed from .github/workflows/test.yml)2
2 files changed, 42 insertions, 1 deletions
diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml
new file mode 100644
index 0000000..4466d7c
--- /dev/null
+++ b/.github/workflows/pull_request.yml
@@ -0,0 +1,41 @@
1name: check
2
3on:
4 pull_request:
5 branches: [ "main" ]
6 workflow_dispatch:
7
8env:
9 SCCACHE_GHA_ENABLED: "true"
10 RUSTC_WRAPPER: "sccache"
11 SQLX_OFFLINE: "true"
12 CARGO_TERM_COLOR: always
13
14jobs:
15 build:
16 runs-on: ubuntu-latest
17 steps:
18 - name: Run sccache-cache
19 uses: mozilla-actions/[email protected]
20
21 - uses: actions/checkout@v4
22 - uses: actions-rs/toolchain@v1
23 with:
24 toolchain: stable
25 components: rustfmt, clippy
26 override: true
27
28 - name: run cargo check
29 uses: actions-rs/cargo@v1
30 with:
31 command: check
32
33 - name: run clippy
34 uses: actions-rs/cargo@v1
35 with:
36 command: clippy
37
38 - name: run test
39 uses: actions-rs/cargo@v1
40 with:
41 command: test
diff --git a/.github/workflows/test.yml b/.github/workflows/push.yml
index 598e5a0..1afe2d3 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/push.yml
@@ -1,4 +1,4 @@
1name: build 1name: build and push
2 2
3on: 3on:
4 push: 4 push: