Skip to content

Commit 7a9cd28

Browse files
authored
Merge pull request #30 from codeforjapan/chore/use-pnpm
migrate into pnpm
2 parents 4da1abf + 7278d35 commit 7a9cd28

File tree

8 files changed

+11255
-9180
lines changed

8 files changed

+11255
-9180
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,20 +29,20 @@ jobs:
2929
with:
3030
persist-credentials: false
3131

32-
- name: Setup Node.js and yarn
32+
- name: Setup Node.js and pnpm
3333
uses: ./.github/workflows/composite/setup
3434

3535
- name: Build
36-
run: yarn run build
36+
run: pnpm run build
3737

3838
- name: Run ESLint
39-
run: yarn run lint
39+
run: pnpm run lint
4040

4141
- name: Run Prettier
42-
run: yarn run format:ci
42+
run: pnpm run format:ci
4343

4444
- name: Run typecheck
45-
run: yarn run typecheck
45+
run: pnpm run typecheck
4646

4747
- name: Run Vitest
48-
run: yarn run test
48+
run: pnpm run test
Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,40 @@
11
name: Setup Node.js
2-
description: Setup Node.js and yarn
2+
description: Setup Node.js and pnpm
33

44
runs:
55
using: composite
66
steps:
7-
- name: Setup yarn
8-
shell: bash
9-
run: corepack enable yarn
7+
- name: Setup pnpm
8+
uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
9+
with:
10+
run_install: false
1011

11-
- name: Get yarn cache directory path
12-
id: yarn-store
12+
- name: Get pnpm store path
13+
id: pnpm-store
1314
shell: bash
14-
run: echo "store_path=$(yarn cache dir)" >> "$GITHUB_OUTPUT"
15+
run: echo "store_path=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT"
1516

1617
- name: Setup Node.js
1718
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
1819
with:
1920
node-version-file: package.json
2021

21-
- name: Restore yarn cache
22+
- name: Restore pnpm cache
2223
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
2324
with:
24-
path: ${{ steps.yarn-store.outputs.store_path }}
25-
key: ${{ runner.os }}-yarn-store-${{ hashFiles('**/yarn.lock') }}
25+
path: ${{ steps.pnpm-store.outputs.store_path }}
26+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
2627
restore-keys: |
27-
${{ runner.os }}-yarn-store-
28+
${{ runner.os }}-pnpm-store-
2829
2930
- name: Install Dependencies
3031
shell: bash
31-
run: yarn install --frozen-lockfile
32+
run: pnpm install --frozen-lockfile
3233

3334
- name: Save pnpm cache if main branch
3435
if: github.ref_name == 'main'
35-
id: save-yarn-cache
36+
id: save-pnpm-cache
3637
uses: actions/cache/save@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
3738
with:
38-
path: ${{ steps.yarn-store.outputs.store_path }}
39-
key: ${{ runner.os }}-yarn-store-${{ hashFiles('**/yarn.lock') }}
39+
path: ${{ steps.pnpm-store.outputs.store_path }}
40+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}

.npmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
save-prefix=''

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
pnpm-lock.yaml

.yarnrc

Lines changed: 0 additions & 1 deletion
This file was deleted.

package.json

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"@mantine/charts": "7.15.2",
2424
"@mantine/core": "7.15.2",
2525
"@mantine/dates": "7.15.2",
26-
"@mantine/form": "^7.15.2",
26+
"@mantine/form": "7.15.2",
2727
"@mantine/hooks": "7.15.2",
2828
"@mantine/modals": "7.15.2",
2929
"@remix-run/node": "2.16.0",
@@ -52,7 +52,6 @@
5252
"@testing-library/react": "16.2.0",
5353
"@testing-library/user-event": "14.6.1",
5454
"@types/eslint-plugin-jsx-a11y": "6.10.0",
55-
"@types/eslint__eslintrc": "3.3.0",
5655
"@types/react": "18.3.18",
5756
"@types/react-dom": "18.3.5",
5857
"@vitejs/plugin-react": "4.3.4",
@@ -70,6 +69,7 @@
7069
"jsdom": "26.0.0",
7170
"msw": "2.7.0",
7271
"orval": "7.3.0",
72+
"pnpm": "10.5.2",
7373
"postcss": "8.4.49",
7474
"postcss-preset-mantine": "1.17.0",
7575
"postcss-simple-vars": "7.0.1",
@@ -86,5 +86,11 @@
8686
"engines": {
8787
"node": ">=20.0.0"
8888
},
89-
"packageManager": "[email protected]"
89+
"packageManager": "[email protected]",
90+
"pnpm": {
91+
"onlyBuiltDependencies": [
92+
"esbuild",
93+
"msw"
94+
]
95+
}
9096
}

0 commit comments

Comments
 (0)