Skip to content

Commit 24d9591

Browse files
authored
chore: migrate to pnpm (#116)
- replaces `yarn` with `pnpm` - enables `minimumReleaseAge` of 1 week - updates dependencies
1 parent 9ae01f5 commit 24d9591

8 files changed

Lines changed: 11259 additions & 11475 deletions

File tree

.github/workflows/ci.yml

Lines changed: 11 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -21,37 +21,32 @@ jobs:
2121
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
2222

2323
steps:
24-
- uses: actions/checkout@v4
24+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2525
with:
2626
fetch-depth: 0
2727

28+
- name: Install pnpm
29+
uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0
30+
2831
- name: Use Node.js ${{ matrix.node-version }}
29-
uses: actions/setup-node@v4
32+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
3033
with:
3134
registry-url: "https://registry.npmjs.org"
3235
node-version: ${{ matrix.node-version }}
36+
cache: "pnpm"
3337

34-
- uses: actions/cache@v4
35-
id: yarn-cache
36-
with:
37-
path: .yarn
38-
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
39-
restore-keys: |
40-
${{ runner.os }}-yarn-
41-
42-
- run: corepack enable
43-
- run: yarn --immutable
38+
- run: pnpm install --frozen-lockfile
4439

45-
- run: yarn ci-build
40+
- run: pnpm run ci-build
4641

47-
- run: yarn ci-test
42+
- run: pnpm run ci-test
4843

49-
- run: yarn ci-lint
44+
- run: pnpm run ci-lint
5045

5146
- name: Publish documentation
5247
if: github.ref == 'refs/heads/master'
5348
run: |
5449
git config user.name "github-actions[bot]"
5550
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
5651
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY
57-
yarn publish:gh-pages
52+
pnpm run publish:gh-pages

.husky/pre-commit

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/usr/bin/env sh
22

3-
yarn lint
4-
yarn lint-staged
3+
pnpm run lint
4+
pnpm exec lint-staged

angular.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@
153153
},
154154
"cli": {
155155
"analytics": "973384b3-6242-4947-9aae-a66f063a7508",
156-
"packageManager": "yarn",
156+
"packageManager": "pnpm",
157157
"schematicCollections": [
158158
"@angular-eslint/schematics"
159159
]

package.json

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -23,66 +23,66 @@
2323
"build": "ng build --project ng-qrcode --configuration production",
2424
"build-for-publish": "ng build --project ng-qrcode --configuration production && cp ./README.md ./CHANGES.md ./LICENSE ./dist/ng-qrcode/",
2525
"build-demo-app": "ng build --project=ng-qrcode-demo --configuration production --base-href '/ng-qrcode/'",
26-
"publish:gh-pages": "yarn build-demo-app && yarn gh-pages -d ./dist/ng-qrcode-demo/browser -b gh-pages --nojekyll",
26+
"publish:gh-pages": "pnpm run build-demo-app && pnpm run gh-pages -d ./dist/ng-qrcode-demo/browser -b gh-pages --nojekyll",
2727
"test": "ng test",
2828
"lint": "ng lint",
29-
"ci-pipeline": "yarn clean && yarn ci-build && yarn ci-test && yarn ci-lint",
29+
"ci-pipeline": "pnpm run clean && pnpm run ci-build && pnpm run ci-test && pnpm run ci-lint",
3030
"postci-pipeline": "cp ./README.md ./CHANGES.md ./LICENSE ./dist/ng-qrcode/",
3131
"ci-build": "ng build --project ng-qrcode --configuration production && ng build --project=ng-qrcode-demo --configuration production",
3232
"ci-test": "ng test --code-coverage",
3333
"ci-lint": "ng lint"
3434
},
3535
"dependencies": {
36-
"@angular/animations": "^20.0.0",
37-
"@angular/common": "^20.0.0",
38-
"@angular/compiler": "^20.0.0",
39-
"@angular/core": "^20.0.0",
40-
"@angular/forms": "^20.0.0",
41-
"@angular/platform-browser": "^20.0.0",
42-
"@angular/platform-browser-dynamic": "^20.0.0",
43-
"@angular/router": "^20.0.0",
36+
"@angular/animations": "^20.3.6",
37+
"@angular/common": "^20.3.6",
38+
"@angular/compiler": "^20.3.6",
39+
"@angular/core": "^20.3.6",
40+
"@angular/forms": "^20.3.6",
41+
"@angular/platform-browser": "^20.3.6",
42+
"@angular/platform-browser-dynamic": "^20.3.6",
43+
"@angular/router": "^20.3.6",
4444
"qrcode": "^1.5.4",
4545
"rxjs": "^7.8.2",
4646
"tslib": "^2.8.1",
4747
"zone.js": "~0.15.1"
4848
},
4949
"devDependencies": {
50-
"@angular-devkit/build-angular": "^20.0.0",
51-
"@angular-eslint/builder": "19.6.0",
52-
"@angular-eslint/eslint-plugin": "19.6.0",
53-
"@angular-eslint/eslint-plugin-template": "19.6.0",
54-
"@angular-eslint/schematics": "19.6.0",
55-
"@angular-eslint/template-parser": "19.6.0",
56-
"@angular/cli": "^20.0.0",
57-
"@angular/compiler-cli": "^20.0.0",
58-
"@angular/language-service": "^20.0.0",
59-
"@types/jasmine": "~5.1.8",
50+
"@angular-devkit/build-angular": "^20.3.6",
51+
"@angular-eslint/builder": "20.4.0",
52+
"@angular-eslint/eslint-plugin": "20.4.0",
53+
"@angular-eslint/eslint-plugin-template": "20.4.0",
54+
"@angular-eslint/schematics": "20.4.0",
55+
"@angular-eslint/template-parser": "20.4.0",
56+
"@angular/cli": "^20.3.6",
57+
"@angular/compiler-cli": "^20.3.6",
58+
"@angular/language-service": "^20.3.6",
59+
"@types/jasmine": "~5.1.12",
6060
"@types/node": "^22.15.29",
6161
"@types/qrcode": "^1.5.5",
62-
"@typescript-eslint/eslint-plugin": "8.33.0",
63-
"@typescript-eslint/parser": "8.33.0",
64-
"eslint": "^9.28.0",
62+
"@typescript-eslint/eslint-plugin": "8.46.1",
63+
"@typescript-eslint/parser": "8.46.1",
64+
"eslint": "^9.38.0",
6565
"gh-pages": "^6.3.0",
6666
"husky": "^9.1.7",
67-
"jasmine-core": "~5.7.1",
67+
"jasmine-core": "~5.12.0",
6868
"jasmine-spec-reporter": "~7.0.0",
6969
"karma": "^6.4.4",
7070
"karma-chrome-launcher": "~3.2.0",
7171
"karma-coverage": "^2.2.1",
7272
"karma-jasmine": "~5.1.0",
7373
"karma-jasmine-html-reporter": "^2.1.0",
74-
"lint-staged": "^16.1.0",
74+
"lint-staged": "^16.2.4",
7575
"markdown-toc": "^1.2.0",
76-
"ng-packagr": "^20.0.0",
77-
"typescript": "~5.8.3"
76+
"ng-packagr": "^20.3.0",
77+
"typescript": "~5.9.3"
7878
},
7979
"lint-staged": {
8080
"*.md": [
81-
"sh -c 'yarn docs:generate'"
81+
"sh -c 'pnpm run docs:generate'"
8282
]
8383
},
8484
"engines": {
8585
"node": ">=20"
8686
},
87-
"packageManager": "yarn@4.9.1"
87+
"packageManager": "pnpm@10.18.3+sha512.bbd16e6d7286fd7e01f6b3c0b3c932cda2965c06a908328f74663f10a9aea51f1129eea615134bf992831b009eabe167ecb7008b597f40ff9bc75946aadfb08d"
8888
}

0 commit comments

Comments
 (0)