File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,8 +2,38 @@ name: Checks
22on :
33 push :
44 branches : [main]
5+ pull_request :
56
67jobs :
8+ lint :
9+ permissions :
10+ contents : read
11+ timeout-minutes : 15
12+ strategy :
13+ matrix :
14+ node : [20]
15+ runs-on : ubuntu-latest
16+ env :
17+ CI : true
18+ steps :
19+ - name : Checkout
20+ uses : actions/checkout@v4
21+
22+ - name : Node.js ${{ matrix.node }}
23+ uses : actions/setup-node@v4.0.2
24+ with :
25+ node-version : ${{ matrix.node }}
26+ cache : " npm"
27+
28+ - name : Install dependencies
29+ run : |
30+ npm ci
31+
32+ - name : Run compas lint
33+ run : |
34+ CI=false npx compas generate
35+ npx compas lint
36+
737 types :
838 permissions :
939 contents : read
3969 timeout-minutes : 15
4070 strategy :
4171 matrix :
42- node : [18, 20]
43- postgresVersion : [12, 13, 14 ]
72+ node : [18, 20, 22 ]
73+ postgresVersion : [12, 14, 16 ]
4474 runs-on : ubuntu-latest
4575 env :
4676 CI : true
82112 timeout-minutes : 15
83113 strategy :
84114 matrix :
85- node : [18 ]
86- postgresVersion : [14 ]
115+ node : [20 ]
116+ postgresVersion : [15 ]
87117 runs-on : ubuntu-latest
88118 env :
89119 CI : true
@@ -121,13 +151,13 @@ jobs:
121151 path : .cache/
122152
123153 - name : Upload coverage
124- if : matrix.node == '18'
125154 uses : codecov/codecov-action@v3
126155 with :
127156 token : ${{ secrets.CODECOV_TOKEN }}
128157 directory : ./coverage
129158
130159 sync-website :
160+ if : ${{ github.event.ref == 'refs/heads/main' }}
131161 permissions :
132162 contents : read
133163 timeout-minutes : 15
@@ -168,6 +198,7 @@ jobs:
168198
169199 analyze :
170200 name : Analyze
201+ if : ${{ github.event.ref == 'refs/heads/main' }}
171202 runs-on : ubuntu-latest
172203 permissions :
173204 security-events : write
Load diff This file was deleted.
You can’t perform that action at this time.
0 commit comments