Skip to content

Commit fe09a22

Browse files
committed
feat!: update to Node.js 24 and modernize CI/CD
BREAKING CHANGES: - Minimum Node.js version updated from v22 to v24 Changes: - Update .nvmrc to v24 - Update package.json engines to >=24.0.0 - Remove legacy workflow files (publish_package.yaml, release-on-tag-push.yaml) - Remove local init-npm action in favor of shared workflows - Update pull_request workflow to use MapColonies/shared-workflows - Add publish workflow with OIDC and npm provenance - Add dependabot configuration for automated dependency updates
1 parent a4a09c1 commit fe09a22

8 files changed

Lines changed: 95 additions & 89 deletions

File tree

.github/actions/init-npm/action.yaml

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

.github/dependabot.yaml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# yaml-language-server: $schema=https://json.schemastore.org/dependabot-2.0.json
2+
version: 2
3+
updates:
4+
# npm dependencies
5+
- package-ecosystem: npm
6+
target-branch: 'master'
7+
schedule:
8+
interval: weekly
9+
allow:
10+
- dependency-type: production
11+
directory: /
12+
commit-message:
13+
prefix: 'deps'
14+
groups:
15+
map-colonies:
16+
patterns:
17+
- '@map-colonies/*'
18+
opentelemetry:
19+
patterns:
20+
- '@opentelemetry/*'
21+
patch:
22+
update-types:
23+
- patch
24+
25+
# npm dev dependencies
26+
- package-ecosystem: npm
27+
schedule:
28+
interval: weekly
29+
allow:
30+
- dependency-type: development
31+
directory: /
32+
commit-message:
33+
prefix: 'devdeps'
34+
groups:
35+
map-colonies:
36+
patterns:
37+
- '@map-colonies/*'
38+
opentelemetry:
39+
patterns:
40+
- '@opentelemetry/*'
41+
types:
42+
patterns:
43+
- '@types/*'
44+
dev-patch:
45+
update-types:
46+
- patch
47+
48+
# GitHub Actions
49+
- package-ecosystem: github-actions
50+
schedule:
51+
interval: weekly
52+
commit-message:
53+
prefix: 'ci'
54+
directory: '/'

.github/workflows/publish.yaml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: publish
2+
3+
on:
4+
workflow_dispatch:
5+
release:
6+
types: [published]
7+
8+
permissions:
9+
id-token: write
10+
contents: read
11+
12+
jobs:
13+
publish:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v4
17+
18+
- name: Init Nodejs
19+
uses: MapColonies/shared-workflows/actions/init-npm@init-npm-v1
20+
with:
21+
node-version: 24.x
22+
23+
- uses: JS-DevTools/npm-publish@v3
24+
with:
25+
token: ${{ secrets.NPM_TOKEN }}
26+
provenance: true

.github/workflows/publish_package.yaml

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

.github/workflows/pull_request.yml

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4,44 +4,38 @@ jobs:
44
tests:
55
name: Run Tests
66
runs-on: ubuntu-latest
7+
78
strategy:
89
matrix:
9-
node: [22.x, 24.x]
10+
node: [24.x]
11+
1012
steps:
1113
- name: Check out TS Project Git repository
1214
uses: actions/checkout@v4
1315

14-
- name: Init nodejs
15-
uses: ./.github/actions/init-npm
16+
- name: Init Nodejs
17+
uses: MapColonies/shared-workflows/actions/init-npm@init-npm-v1
1618
with:
1719
node-version: ${{ matrix.node }}
18-
skip-build: true
1920

2021
- name: Run tests
2122
run: npm run test
2223

2324
- uses: actions/upload-artifact@v4
2425
with:
25-
name: Test Reporters-${{ matrix.node }}
26-
path: reports/**
26+
name: Test Reporters ${{ matrix.node }}
27+
path: ./reports/**
2728

2829
eslint:
2930
name: Run TS Project eslint
3031
runs-on: ubuntu-latest
31-
steps:
32-
- name: Check out TS Project Git repository
33-
uses: actions/checkout@v4
3432

35-
- name: Init nodejs
36-
uses: ./.github/actions/init-npm
37-
with:
38-
skip-build: true
33+
strategy:
34+
matrix:
35+
node: [24.x]
3936

37+
steps:
4038
- name: Run TS Project linters
41-
uses: wearerequired/lint-action@v2
39+
uses: MapColonies/shared-workflows/actions/eslint@eslint-v1.0.1
4240
with:
43-
github_token: ${{ secrets.github_token }}
44-
# Enable linters
45-
eslint: true
46-
prettier: true
47-
eslint_extensions: ts
41+
node_version: ${{ matrix.node }}

.github/workflows/release-on-tag-push.yaml

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

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v22
1+
v24

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
"prepare": "husky"
2323
},
2424
"engines": {
25-
"node": ">=22.0.0"
25+
"node": ">=24.0.0"
2626
},
2727
"repository": {
2828
"type": "git",

0 commit comments

Comments
 (0)