Skip to content

Commit 95a59ff

Browse files
committed
chore: migrate to pnpm
1 parent 4a29bce commit 95a59ff

File tree

9 files changed

+8531
-6771
lines changed

9 files changed

+8531
-6771
lines changed

.github/workflows/ci.yml

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -18,31 +18,25 @@ jobs:
1818
node: [14]
1919

2020
steps:
21+
- uses: actions/checkout@v4
22+
- run: corepack enable
2123
- uses: actions/setup-node@v4
2224
with:
2325
node-version: ${{ matrix.node }}
26+
cache: pnpm
27+
- uses: actions/setup-node@v4
2428

25-
- name: checkout
26-
uses: actions/checkout@v4
27-
28-
- name: cache node_modules
29-
uses: actions/cache@v4
30-
with:
31-
path: node_modules
32-
key: ${{ matrix.os }}-node-v${{ matrix.node }}-deps-${{ hashFiles(format('{0}{1}', github.workspace, '/yarn.lock')) }}
33-
34-
- name: Install dependencies
35-
if: steps.cache.outputs.cache-hit != 'true'
36-
run: yarn
29+
- name: 📦 Install dependencies
30+
run: pnpm install
3731

38-
- name: Lint
39-
run: yarn lint
32+
- name: 🔠 Lint project
33+
run: pnpm lint
4034

41-
- name: Build
42-
run: yarn build
35+
- name: 🛠 Build project
36+
run: pnpm build
4337

44-
- name: Test
45-
run: yarn test:coverage
38+
- name: 🧪 Test
39+
run: pnpm test:coverage
4640

47-
- name: Coverage
41+
- name: 🟩 Coverage
4842
uses: codecov/codecov-action@v5

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,9 @@ production or running a CI pipeline. That's why the message is
9797
## Development
9898

9999
- Clone this repository
100-
- Install dependencies using `yarn install` or `npm install`
100+
- Install dependencies using `pnpm install`
101101
- Run it manually `path/to/project/root/src/index.js path/to/package/you/want/to/try`
102-
- Run tests with `npm t` or `yarn test`
102+
- Run tests with `npm t` or `pnpm test`
103103

104104
## Inspiration
105105

package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
"scripts": {
1313
"build": "bili -t node --format cjs src/index.js",
1414
"lint": "eslint src test",
15-
"prepublish": "yarn build",
15+
"prepublish": "pnpm build",
1616
"release": "standard-version && git push --follow-tags && npm publish",
17-
"test": "yarn lint && yarn test:coverage",
17+
"test": "pnpm lint && pnpm test:coverage",
1818
"test:ava": "nyc ava --verbose",
1919
"test:coverage": "nyc --reporter=lcov --reporter=html ava"
2020
},
@@ -45,5 +45,6 @@
4545
"engines": {
4646
"node": ">=8.17.0",
4747
"npm": ">=5.10.0"
48-
}
48+
},
49+
"packageManager": "pnpm@9.15.0"
4950
}

0 commit comments

Comments
 (0)