Skip to content

Commit 7acb5ff

Browse files
authored
chore: refactor CI (#258)
* ci: refactor CI * ci: fix bun filter * docs: include build and bun steps * chore: rename CodeQL workflow * docs: fix CodeQL badge * ci: refactor CI * chore: comment difference between dependency bots
1 parent c78787e commit 7acb5ff

21 files changed

+218
-180
lines changed

.github/dependabot.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# Focuses on major updates, dependabot creates separate PRs for each dependency update
12
version: 2
23
updates:
34
- package-ecosystem: 'npm'

.github/workflows/deps-docs-update.yml renamed to .github/workflows/bot_deps-docs-update.yml

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
name: '⏫ (📒)'
1+
# Groups minor and patch dependency updates into a single PR.
2+
name: '⏫ Bot (Website) — Dependencies'
23

34
on:
45
schedule:
@@ -8,7 +9,7 @@ on:
89
jobs:
910
update-deps:
1011
runs-on: ubuntu-latest
11-
name: Dependencies Update
12+
name: Update
1213
steps:
1314
- name: ➕ Actions - Checkout
1415
uses: actions/checkout@v4

.github/workflows/deps-update.yml renamed to .github/workflows/bot_deps-update.yml

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
name: ''
1+
# Groups minor and patch dependency updates into a single PR.
2+
name: '⏫ Bot — Dependencies'
23

34
on:
45
schedule:
@@ -8,7 +9,7 @@ on:
89
jobs:
910
update-deps:
1011
runs-on: ubuntu-latest
11-
name: Dependencies Update
12+
name: Update
1213
steps:
1314
- name: ➕ Actions - Checkout
1415
uses: actions/checkout@v4

.github/workflows/stale.yml renamed to .github/workflows/bot_stale.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: '🧹'
1+
name: '🧹 Bot — Stale'
22

33
on:
44
schedule:
@@ -8,7 +8,7 @@ on:
88
jobs:
99
stale:
1010
runs-on: ubuntu-latest
11-
name: Stale Issues and PRs
11+
name: Issues and PRs
1212
steps:
1313
- uses: actions/stale@v9
1414
with:

.github/workflows/docs-deploy.yml renamed to .github/workflows/cd_docs-deploy.yml

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
name: '🚀'
1+
name: '🚀 CD (Website) — Publish'
2+
23
on:
34
push:
45
branches:
@@ -11,7 +12,7 @@ jobs:
1112
deploy:
1213
runs-on: ubuntu-latest
1314
timeout-minutes: 15
14-
name: Deploy Website
15+
name: Deploy
1516
steps:
1617
- name: Actions - Checkout
1718
uses: actions/checkout@v4

.github/workflows/release-please.yml renamed to .github/workflows/cd_publish.yml

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
1-
name: '📩'
1+
name: '🚀 CD — Publish'
2+
23
on:
34
push:
45
branches:
56
- main
67
workflow_dispatch:
8+
79
permissions:
810
contents: write
911
pull-requests: write
12+
1013
jobs:
1114
release-please:
1215
runs-on: ubuntu-latest

.github/workflows/ci.yml

-123
This file was deleted.

.github/workflows/ci-codeql.yml renamed to .github/workflows/ci_codeql.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# the `language` matrix defined below to confirm you have the correct set of
1010
# supported CodeQL languages.
1111
#
12-
name: '🔎'
12+
name: '🔎 CI — CodeQL'
1313

1414
on:
1515
push:
@@ -20,7 +20,7 @@ on:
2020

2121
jobs:
2222
analyze:
23-
name: CodeQL
23+
name: Analyze
2424
# Runner size impacts CodeQL analysis time. To learn more, please see:
2525
# - https://gh.io/recommended-hardware-resources-for-running-codeql
2626
# - https://gh.io/supported-runners-and-hardware-resources
+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: '🔬 CI — Compatibility'
2+
3+
on:
4+
push:
5+
branches:
6+
- 'main'
7+
pull_request:
8+
workflow_dispatch:
9+
10+
jobs:
11+
bun:
12+
runs-on: ubuntu-latest
13+
timeout-minutes: 5
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
bun-version: ['latest', 'canary']
18+
name: Bun ${{ matrix.bun-version }}
19+
steps:
20+
- name: ➕ Actions - Checkout
21+
uses: actions/checkout@v4
22+
23+
- name: ➕ Actions - Setup NodeJS
24+
uses: actions/setup-node@v4
25+
with:
26+
node-version: '22.x'
27+
28+
- name: ➕ Cache dependencies
29+
uses: actions/cache@v4
30+
with:
31+
path: ~/.npm
32+
key: npm-linux-${{ hashFiles('package-lock.json') }}
33+
restore-keys: npm-linux-
34+
35+
- name: 📦 Installing Dependencies
36+
run: npm ci
37+
38+
- name: 🤹🏻‍♀️ Building the Project
39+
run: npm run build
40+
41+
# Testing via Docker Official Images
42+
- name: 🔬 Bun ${{ matrix.bun-version }}
43+
run: FILTER=bun-${{ matrix.bun-version }} npm run test:ci
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: '🔬 CI — Compatibility'
2+
3+
on:
4+
push:
5+
branches:
6+
- 'main'
7+
pull_request:
8+
workflow_dispatch:
9+
10+
jobs:
11+
deno:
12+
runs-on: ubuntu-latest
13+
timeout-minutes: 5
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
deno-version: ['latest']
18+
name: Deno ${{ matrix.deno-version }}
19+
steps:
20+
- name: ➕ Actions - Checkout
21+
uses: actions/checkout@v4
22+
23+
- name: ➕ Actions - Setup NodeJS
24+
uses: actions/setup-node@v4
25+
with:
26+
node-version: '22.x'
27+
28+
- name: ➕ Cache dependencies
29+
uses: actions/cache@v4
30+
with:
31+
path: ~/.npm
32+
key: npm-linux-${{ hashFiles('package-lock.json') }}
33+
restore-keys: npm-linux-
34+
35+
- name: 📦 Installing Dependencies
36+
run: npm ci
37+
38+
# Testing via Docker Official Images
39+
- name: 🔬 Deno ${{ matrix.deno-version }}
40+
run: FILTER=deno-${{ matrix.deno-version }} npm run test:ci
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: '🔬 CI — Compatibility'
2+
3+
on:
4+
push:
5+
branches:
6+
- 'main'
7+
pull_request:
8+
workflow_dispatch:
9+
10+
jobs:
11+
node:
12+
runs-on: ubuntu-latest
13+
timeout-minutes: 5
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
node-version:
18+
[
19+
'06',
20+
'07',
21+
'08',
22+
'09',
23+
'10',
24+
'11',
25+
'12',
26+
'13',
27+
'14',
28+
'15',
29+
'16',
30+
'17',
31+
'18',
32+
'19',
33+
'20',
34+
'21',
35+
'latest',
36+
]
37+
name: Node.js ${{ matrix.node-version }}
38+
steps:
39+
- name: ➕ Actions - Checkout
40+
uses: actions/checkout@v4
41+
42+
- name: ➕ Actions - Setup NodeJS
43+
uses: actions/setup-node@v4
44+
with:
45+
node-version: '22.x'
46+
47+
- name: ➕ Cache dependencies
48+
uses: actions/cache@v4
49+
with:
50+
path: ~/.npm
51+
key: npm-linux-${{ hashFiles('package-lock.json') }}
52+
restore-keys: npm-linux-
53+
54+
- name: 📦 Installing Dependencies
55+
run: npm ci
56+
57+
- name: 🤹🏻‍♀️ Building the Project
58+
run: npm run build
59+
60+
# Testing via Docker Official Images
61+
- name: 🔬 Node ${{ matrix.node-version }}
62+
run: FILTER=node-${{ matrix.node-version }} npm run test:ci

0 commit comments

Comments
 (0)