Skip to content

Commit 6132aa2

Browse files
Yarn & Node.js upgrade (#126)
1 parent 8c7a284 commit 6132aa2

File tree

8 files changed

+8244
-4792
lines changed

8 files changed

+8244
-4792
lines changed

.github/workflows/javascript-test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }}
2727
restore-keys: ${{ runner.os }}-build-${{ env.cache-name }}-
2828
- name: Install dependencies
29-
run: yarn install --frozen-lockfile
29+
run: yarn install --immutable
3030
- run: yarn run ${{ matrix.command }}
3131

3232
conclude:

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/node_modules
22
/dist*
33
.env
4+
.yarn/install-state.gz
45

56
# Editor directories and files
67
.vscode/*

.yarn/releases/yarn-4.3.0.cjs

Lines changed: 894 additions & 0 deletions
Large diffs are not rendered by default.

.yarnrc.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
nodeLinker: node-modules
2+
3+
yarnPath: .yarn/releases/yarn-4.3.0.cjs

Dockerfile

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,17 @@
1-
FROM node:20 as Builder
1+
FROM node:22 as Builder
22

33
WORKDIR /action
44

5-
COPY package.json yarn.lock ./
5+
COPY .yarn/ ./.yarn/
6+
COPY package.json yarn.lock .yarnrc.yml ./
67

7-
RUN yarn install --frozen-lockfile
8+
RUN yarn install --immutable
89

910
COPY . .
1011

1112
RUN yarn run build
1213

13-
FROM node:20-slim
14+
FROM node:22-slim
1415

1516
COPY --from=Builder /action/dist /action
1617

package.json

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@
88
"build": "ncc build --license LICENSE",
99
"cli": "ncc build src/cli.ts -o dist-cli && node dist-cli",
1010
"test": "jest",
11-
"fix": "eslint --fix '{src,test}/**/*'",
12-
"lint": "eslint '{src,test}/**/*'"
11+
"fix": "npx eslint --fix 'src/**/*.ts' && npx prettier --write 'src/**/*.{ts,yml}'",
12+
"lint": "npx eslint 'src/**/*.ts' && npx prettier --check 'src/**/*.{ts,yml}'"
1313
},
1414
"engines": {
15-
"node": ">=20.0.0"
15+
"node": ">=22.0.0"
1616
},
1717
"repository": {
1818
"type": "git",
@@ -25,21 +25,22 @@
2525
},
2626
"homepage": "https://github.com/paritytech/review-bot#readme",
2727
"devDependencies": {
28-
"@eng-automation/js-style": "^2.3.0",
28+
"@eng-automation/js-style": "^3.1.0",
2929
"@octokit/webhooks-types": "^7.3.1",
3030
"@types/jest": "^29.5.11",
3131
"@vercel/ncc": "^0.38.1",
3232
"jest": "^29.7.0",
3333
"jest-mock-extended": "^3.0.5",
3434
"ts-jest": "^29.1.2",
35-
"typescript": "^5.3.3"
35+
"typescript": "^5.4.5"
3636
},
3737
"dependencies": {
3838
"@actions/core": "^1.10.1",
3939
"@actions/github": "^6.0.0",
40-
"@eng-automation/js": "^1.0.2",
41-
"@polkadot/api": "^10.13.1",
42-
"joi": "^17.6.4",
40+
"@eng-automation/js": "^2.2.0",
41+
"@polkadot/api": "^11.3.1",
42+
"joi": "^17.13.1",
4343
"yaml": "^2.3.4"
44-
}
44+
},
45+
"packageManager": "yarn@4.3.0"
4546
}

src/test/config.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
rules:
22
- name: CI files
33
condition:
4-
include:
4+
include:
55
- ^\.gitlab-ci\.yml
66
- ^docker/.*
77
- ^\.github/.*
88
- ^\.gitlab/.*
99
- ^\.config/nextest.toml
1010
- ^\.cargo/.*
11-
exclude:
11+
exclude:
1212
- ^./gitlab/pipeline/zombienet.yml$
1313
minApprovals: 2
1414
type: basic
@@ -19,12 +19,12 @@ rules:
1919
- name: Audit rules
2020
type: basic
2121
condition:
22-
include:
22+
include:
2323
- ^polkadot/runtime\/(kusama|polkadot|common)\/.*
2424
- ^polkadot/primitives/src\/.+\.rs$
2525
- ^substrate/primitives/.*
2626
- ^substrate/frame/.*
27-
exclude:
27+
exclude:
2828
- ^polkadot/runtime\/(kusama|polkadot)\/src\/weights\/.+\.rs$
2929
- ^substrate\/frame\/.+\.md$
3030
minApprovals: 2
@@ -77,7 +77,7 @@ rules:
7777
# if there are any changes in the bridges subtree (in case of backport changes back to bridges repo)
7878
- name: Bridges subtree files
7979
type: basic
80-
condition:
80+
condition:
8181
include:
8282
- ^cumulus/bridges/.*
8383
minApprovals: 1
@@ -88,7 +88,7 @@ rules:
8888

8989
- name: FRAME coders substrate
9090
condition:
91-
include:
91+
include:
9292
- ^substrate/frame/(?!.*(nfts/.*|uniques/.*|babe/.*|grandpa/.*|beefy|merkle-mountain-range/.*|contracts/.*|election|nomination-pools/.*|staking/.*|aura/.*))
9393
type: "and"
9494
reviewers:

0 commit comments

Comments
 (0)