Skip to content

Commit 4a24ee8

Browse files
committed
chore(ci): simplify CI
1 parent 4cd0b77 commit 4a24ee8

2 files changed

Lines changed: 36 additions & 197 deletions

File tree

Lines changed: 36 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,38 @@ name: Checks
22
on:
33
push:
44
branches: [main]
5+
pull_request:
56

67
jobs:
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
@@ -39,8 +69,8 @@ jobs:
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
@@ -82,8 +112,8 @@ jobs:
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

‎.github/workflows/pr-checks.yml‎

Lines changed: 0 additions & 192 deletions
This file was deleted.

0 commit comments

Comments
 (0)