Skip to content

Commit b910cd4

Browse files
committed
chore: switch to pnpm
1 parent 2eef04a commit b910cd4

File tree

18 files changed

+13743
-38349
lines changed

18 files changed

+13743
-38349
lines changed

.github/workflows/test.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,19 @@ jobs:
2626
uses: actions/setup-node@v4
2727
with:
2828
node-version: ${{ matrix.node }}
29+
cache: pnpm
30+
cache-dependency-path: pnpm-lock.yaml
2931

30-
- name: Cache Node Modules
31-
id: cache-node-modules
32-
uses: actions/cache@v4
32+
- name: Set up pnpm
33+
uses: pnpm/action-setup@v4
3334
with:
34-
path: node_modules
35-
key: node-modules-${{ hashFiles('package-lock.json') }}
35+
version: 10.28.0
3636

3737
- name: Install dependencies
38-
run: npm ci
38+
run: pnpm install
3939

4040
- name: Run tests
41-
run: npm run test:ci
41+
run: pnpm run test:ci
4242

4343
- name: SonarCloud Scan
4444
uses: SonarSource/sonarcloud-github-action@master

.husky/commit-msg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
npx --no -- commitlint --edit "$1"
1+
pnpm exec commitlint --edit "$1"

.husky/pre-commit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
npx --no-install lint-staged
1+
pnpm exec lint-staged

.npmrc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
lockfile-version=2
1+
prefer-workspace-packages=true
2+
shared-workspace-lockfile=true

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,14 +51,14 @@ Try and avoid making breaking changes. Those take more time to ship. Instead mak
5151

5252
Features should be accompanied with tests and documentation.
5353

54-
Don't include unrelated changes in your pull request. Make sure tests pass on your machine by running `npm test`. You can run specific test files as well using `npm run test -- packages/.../{file}.js`.
54+
Don't include unrelated changes in your pull request. Make sure tests pass on your machine by running `pnpm test`. You can run specific test files as well using `pnpm run test -- packages/.../{file}.js`.
5555

5656
When you make a pull request please use a clear and descriptive title. Be specific about what's changed and why.
5757

5858
Please make sure the *Allow edits from maintainers* box is checked. That way we can make certain minor changes ourselves, allowing your pull request to be merged sooner.
5959

6060
You might be asked to make changes to your pull request. There's never a need to open another pull request. Push more commits to your existing branch. We'll squash them when we merge the PR.
6161

62-
Dependencies are managed using `npm`. Only update dependencies when needed for your pull request. Don't rebuild the lockfile.
62+
Dependencies are managed using `pnpm`. Only update dependencies when needed for your pull request. Don't rebuild the lockfile.
6363

6464
And finally, have fun!

jest.preset.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export default {
1414
tsconfig: '<rootDir>/tsconfig.json',
1515
}]
1616
},
17-
transformIgnorePatterns: ['node_modules/(?!(serialize-error)|(exit-hook)|(chalk)|(find-cache-dir)|(pkg-dir)|(find-up)|(locate-path)|(p-locate)|(p-limit)|(yocto-queue)|(path-exists)|(change-case))'],
17+
transformIgnorePatterns: ['node_modules/(?!(\\.pnpm)|(serialize-error)|(exit-hook)|(chalk)|(find-cache-dir)|(pkg-dir)|(find-up)|(locate-path)|(p-locate)|(p-limit)|(yocto-queue)|(path-exists)|(change-case))'],
1818
preset: 'ts-jest/presets/js-with-ts-esm',
1919
moduleDirectories: ['node_modules', `${__dirname}/packages`],
2020
coverageReporters: ['text', 'clover', 'json', 'lcov'],

lerna.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"version": "4.0.3",
3+
"npmClient": "pnpm",
34
"packages": ["packages/*"],
45
"command": {
56
"bootstrap": {

0 commit comments

Comments
 (0)