@@ -3,56 +3,24 @@ name: ci
33on : [push, pull_request]
44
55jobs :
6- rust :
7- name : deno_cache_dir-${{ matrix.os }}
8- if : |
9- github.event_name == 'push' ||
10- !startsWith(github.event.pull_request.head.label, 'denoland:')
6+ deno :
7+ name : deno_cache_dir ${{ matrix.os }}
118 runs-on : ${{ matrix.os }}
129 timeout-minutes : 30
1310 strategy :
1411 matrix :
1512 os : [macOS-latest, ubuntu-latest, windows-latest]
16-
17- steps :
18- - name : Clone repository
19- uses : actions/checkout@v5
20-
21- - name : Install rust
22- uses : dsherret/rust-toolchain-file@v1
23-
24- - uses : Swatinem/rust-cache@v2
25- with :
26- save-if : ${{ github.ref == 'refs/heads/main' }}
27-
28- - name : Format
29- if : contains(matrix.os, 'ubuntu')
30- run : cargo fmt --check
31-
32- - name : Clippy
33- if : contains(matrix.os, 'ubuntu')
34- run : cargo clippy
35-
36- - name : Build (sync)
37- run : cargo build --features sync
38-
39- - name : Test
40- run : cargo test
41-
42- deno :
43- name : deno_cache_dir-deno
4413 if : |
4514 github.event_name == 'push' ||
4615 !startsWith(github.event.pull_request.head.label, 'denoland:')
47- runs-on : ubuntu-latest
4816 permissions :
4917 contents : read
5018 id-token : write
5119 timeout-minutes : 30
5220
5321 steps :
5422 - name : Clone repository
55- uses : actions/checkout@v5
23+ uses : actions/checkout@v6
5624 - name : Install rust
5725 uses : dsherret/rust-toolchain-file@v1
5826 - uses : Swatinem/rust-cache@v2
@@ -64,13 +32,16 @@ jobs:
6432 deno-version : canary
6533
6634 - name : Format
67- run : deno fmt --check
35+ if : contains(matrix.os, 'ubuntu')
36+ run : cargo fmt --check && deno fmt --check
37+ - name : Clippy
38+ if : contains(matrix.os, 'ubuntu')
39+ run : cargo clippy && deno lint
6840 - name : Build
6941 run : deno task build
70- - name : Lint
71- run : deno lint
7242 - name : Test
7343 run : deno task test
7444
7545 - name : Publish JSR
46+ if : contains(matrix.os, 'ubuntu')
7647 run : deno run -A jsr:@david/publish-on-tag@0.1.3
0 commit comments