Skip to content

Commit 6261424

Browse files
committed
upgrade to yarn v4, remove incompatible github actions
1 parent 4cf53c0 commit 6261424

File tree

12 files changed

+22171
-15317
lines changed

12 files changed

+22171
-15317
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ jobs:
114114
- checkout
115115
- *set_npm_token
116116
- *restore_yarn_cache
117-
- run: yarn --production=false --frozen-lockfile
117+
- run: yarn install --immutable
118118
- *save_yarn_cache
119119
- *save_node_modules
120120

.github/actions/yarn/action.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: 'Restore Yarn Cache'
2+
description: 'Setup a NodeJS environment and restore cache if any, given a node version'
3+
4+
runs:
5+
using: 'composite'
6+
steps:
7+
- name: Setup Node.js
8+
uses: actions/setup-node@v4
9+
with:
10+
node-version-file: .nvmrc
11+
- uses: actions/cache@v4
12+
with:
13+
path: |
14+
**/node_modules
15+
key: v1-yarn-${{ runner.os }}-${{ hashFiles('.nvmrc') }}-${{ hashFiles('**/yarn.lock') }}
16+
- name: Install Dependencies If Not Cached
17+
run: \[ -d node_modules \] || yarn install --immutable
18+
shell: bash

.github/workflows/auto-request-reviews.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
runs-on: ubuntu-latest
1313
if: github.event.pull_request.draft == false
1414
steps:
15-
- uses: actions/checkout@v2
15+
- uses: actions/checkout@v4
1616
- name: Request review based on files changed
1717
uses: ohnogumi/[email protected]
1818
with:

.github/workflows/codeql-analysis.yml

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

.github/workflows/push.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,9 @@ jobs:
44
format:
55
runs-on: ubuntu-latest
66
steps:
7-
- uses: Codecademy/[email protected]
8-
with:
9-
node-version: 22
10-
command: format:verify
7+
- uses: actions/checkout@v4
8+
- uses: ./.github/actions/yarn
9+
- run: yarn format:verify
1110

1211
lint:
1312
strategy:
@@ -16,10 +15,8 @@ jobs:
1615
command: ['lint', 'verify']
1716
runs-on: ubuntu-latest
1817
steps:
19-
- uses: Codecademy/[email protected]
20-
with:
21-
node-version: 22
22-
command: build
18+
- uses: actions/checkout@v4
19+
- uses: ./.github/actions/yarn
2320
- run: yarn ${{ matrix.command }}
2421

2522
on:

.gitignore

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,15 @@ tmp
3232
.npmrc
3333
.awcache
3434

35+
# Yarn specific ignores
36+
.pnp.*
37+
.yarn/*
38+
!.yarn/patches
39+
!.yarn/plugins
40+
!.yarn/releases
41+
!.yarn/sdks
42+
!.yarn/versions
43+
3544
# Users Environment Variables
3645
.lock-wscript
3746

.lintstagedrc.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export default {
1010
}
1111

1212
if (micromatch.some(allChanges, 'yarn.lock')) {
13-
commands.push(`npx yarn-deduplicate`);
13+
commands.push(`yarn dedupe`);
1414
}
1515

1616
const eslintExtensions = `{mdx,ts,tsx,js,jsx,json}`;

.yarn/releases/yarn-4.9.1.cjs

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

.yarnrc

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

.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.9.1.cjs

0 commit comments

Comments
 (0)