Skip to content

Commit 544abe2

Browse files
authored
feat: switch to pnpm (#99)
* feat: switch to `pnpm` * remove `{{action}}` helper
1 parent 16410c3 commit 544abe2

File tree

18 files changed

+17411
-14066
lines changed

18 files changed

+17411
-14066
lines changed

.github/workflows/ci.yml

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,20 @@ jobs:
1919

2020
steps:
2121
- uses: actions/checkout@v4
22+
- uses: pnpm/action-setup@v4
2223
- uses: actions/setup-node@v4
2324
with:
2425
node-version: 18
25-
cache: yarn
26+
cache: pnpm
2627

2728
- name: Install Dependencies
28-
run: until yarn install --frozen-lockfile; do echo "Retrying yarn"; done
29+
run: until pnpm install --frozen-lockfile; do echo "Retrying pnpm"; done
2930

3031
- name: Lint
31-
run: yarn lint
32+
run: pnpm lint
3233

3334
- name: Run Tests
34-
run: yarn test
35+
run: pnpm test
3536

3637
floating:
3738
name: "Floating Dependencies"
@@ -40,18 +41,18 @@ jobs:
4041

4142
steps:
4243
- uses: actions/checkout@v4
44+
- uses: pnpm/action-setup@v4
4345
- uses: actions/setup-node@v4
4446
with:
4547
node-version: 18
46-
cache: yarn
48+
cache: pnpm
4749

4850
- name: Install Dependencies
49-
# Absurdly, yarn always fails on the first try here.
50-
# https://github.com/yarnpkg/yarn/issues/2629
51-
run: until yarn install --no-lockfile; do echo "Retrying yarn"; done
51+
52+
run: until pnpm install --no-lockfile; do echo "Retrying pnpm"; done
5253

5354
- name: Run Tests
54-
run: yarn test
55+
run: pnpm test
5556

5657
try-scenarios:
5758
name: ${{ matrix.try-scenario }}
@@ -78,13 +79,14 @@ jobs:
7879

7980
steps:
8081
- uses: actions/checkout@v4
82+
- uses: pnpm/action-setup@v4
8183
- uses: actions/setup-node@v4
8284
with:
8385
node-version: 18
84-
cache: yarn
86+
cache: pnpm
8587

8688
- name: Install Dependencies
87-
run: until yarn install --frozen-lockfile; do echo "Retrying yarn"; done
89+
run: until pnpm install --frozen-lockfile; do echo "Retrying pnpm"; done
8890

8991
- name: Run Tests
9092
run: ./node_modules/.bin/ember try:one ${{ matrix.try-scenario }} --skip-cleanup

.github/workflows/push-dist.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,13 @@ jobs:
1919

2020
steps:
2121
- uses: actions/checkout@v4
22+
- uses: pnpm/action-setup@v4
2223
- uses: actions/setup-node@v4
2324
with:
2425
node-version: 18
25-
cache: yarn
26+
cache: pnpm
2627
- name: Install Dependencies
27-
run: yarn install --frozen-lockfile
28+
run: pnpm install --frozen-lockfile
2829
- uses: kategengler/[email protected]
2930
with:
3031
branch: dist

.gitignore

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,3 @@ npm-debug.log*
1010
yarn-error.log
1111
/.DS_Store
1212

13-
14-
# https://yarnpkg.com/getting-started/qa/#which-files-should-be-gitignored
15-
.yarn/*
16-
!.yarn/cache
17-
!.yarn/patches
18-
!.yarn/plugins
19-
!.yarn/releases
20-
!.yarn/sdks
21-
!.yarn/versions

CONTRIBUTING.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,28 +4,28 @@
44

55
- `git clone https://github.com/villander/ember-engines-router-service.git`
66
- `cd ember-engines-router-service`
7-
- `yarn install`
7+
- `pnpm install`
88

99
## Linting
1010

11-
- `yarn lint`
12-
- `yarn lint:fix`
11+
- `pnpm lint`
12+
- `pnpm lint:fix`
1313

1414
## Building the addon
1515

1616
- `cd ember-engines-router-service`
17-
- `yarn build`
17+
- `pnpm build`
1818

1919
## Running tests
2020

2121
- `cd test-app`
22-
- `yarn test` – Runs the test suite on the current Ember version
23-
- `yarn test:watch` – Runs the test suite in "watch mode"
22+
- `pnpm test` – Runs the test suite on the current Ember version
23+
- `pnpm test:watch` – Runs the test suite in "watch mode"
2424

2525
## Running the test application
2626

2727
- `cd test-app`
28-
- `yarn start`
28+
- `pnpm start`
2929
- Visit the test application at [http://localhost:4200](http://localhost:4200).
3030

3131
For more information on using ember-cli, visit [https://cli.emberjs.com/release/](https://cli.emberjs.com/release/).

RELEASE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Once the prep work is completed, the actual release is straight forward:
3131
* First, ensure that you have installed your projects dependencies:
3232

3333
```sh
34-
yarn install
34+
pnpm install
3535
```
3636

3737
* Second, ensure that you have obtained a

config/ember-cli-update.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"options": [
1313
"--ci-provider=github",
1414
"--release-it",
15-
"--yarn"
15+
"--pnpm"
1616
]
1717
}
1818
]

ember-engines-router-service/package.json

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,6 @@
1010
"url": "git+https://github.com/villander/ember-engines-router-service.git"
1111
},
1212
"license": "MIT",
13-
"authors": [
14-
"Michael Villander"
15-
],
1613
"exports": {
1714
".": "./dist/index.js",
1815
"./*": {
@@ -35,8 +32,8 @@
3532
],
3633
"scripts": {
3734
"build": "rollup --config",
38-
"lint": "concurrently 'yarn:lint:*(!fix)' --names 'lint:'",
39-
"lint:fix": "concurrently 'yarn:lint:*:fix' --names 'fix:'",
35+
"lint": "concurrently 'pnpm:lint:*(!fix)' --names 'lint:'",
36+
"lint:fix": "concurrently 'pnpm:lint:*:fix' --names 'fix:'",
4037
"lint:hbs": "ember-template-lint . --no-error-on-unmatched-pattern",
4138
"lint:hbs:fix": "ember-template-lint . --fix --no-error-on-unmatched-pattern",
4239
"lint:js": "eslint . --cache",
@@ -59,6 +56,7 @@
5956
"@types/ember__routing": "^4.0.22",
6057
"babel-plugin-ember-template-compilation": "^2.2.5",
6158
"concurrently": "^8.2.2",
59+
"ember-source": "^6.4.0",
6260
"ember-template-lint": "^6.0.0",
6361
"eslint": "^8.57.0",
6462
"eslint-config-prettier": "^9.1.0",
@@ -70,12 +68,12 @@
7068
"prettier-plugin-ember-template-tag": "^2.0.2",
7169
"rollup": "^4.18.1"
7270
},
73-
"peerDependencies": {
74-
"ember-source": "^3.28.0 || ^4.0.0 || ^5.0.0"
75-
},
7671
"publishConfig": {
7772
"registry": "https://registry.npmjs.org"
7873
},
74+
"authors": [
75+
"Michael Villander"
76+
],
7977
"ember": {
8078
"edition": "octane"
8179
},
@@ -88,4 +86,4 @@
8886
"./services/engine-router-service.js": "./dist/_app_/services/engine-router-service.js"
8987
}
9088
}
91-
}
89+
}

package.json

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,27 +5,24 @@
55
"type": "git",
66
"url": "https://github.com/villander/ember-engines-router-service"
77
},
8-
"workspaces": [
9-
"ember-engines-router-service",
10-
"test-app"
11-
],
128
"scripts": {
13-
"build": "yarn workspace ember-engines-router-service run build",
14-
"lint": "yarn workspaces run lint",
15-
"lint:fix": "yarn workspaces run lint:fix",
16-
"prepare": "yarn build",
9+
"build": "pnpm -F ember-engines-router-service build",
10+
"lint": "pnpm -r lint --if-present",
11+
"lint:fix": "pnpm -r lint:fix --if-present",
12+
"prepare": "pnpm build",
1713
"release": "release-it",
18-
"start": "concurrently 'yarn:start:*' --restart-after 5000 --prefix-colors cyan,white,yellow",
19-
"start:addon": "yarn workspace ember-engines-router-service run start",
20-
"start:test-app": "yarn workspace test-app run start",
21-
"test": "yarn workspaces run test",
22-
"test:ember": "yarn workspace test-app run test:ember"
14+
"start": "concurrently 'pnpm:start:*' --restart-after 5000 --prefix-colors cyan,white,yellow",
15+
"start:addon": "pnpm -F ember-engines-router-service start",
16+
"start:test-app": "pnpm -F test-app start",
17+
"test": "pnpm -r test --if-present",
18+
"test:ember": "pnpm -F test-app test:ember"
2319
},
2420
"devDependencies": {
2521
"@release-it-plugins/lerna-changelog": "^7.0.0",
2622
"@release-it-plugins/workspaces": "^4.2.0",
2723
"release-it": "^17.5.0"
2824
},
25+
"packageManager": "[email protected]+sha512.f0dda8580f0ee9481c5c79a1d927b9164f2c478e90992ad268bbb2465a736984391d6333d2c327913578b2804af33474ca554ba29c04a8b13060a717675ae3ac",
2926
"publishConfig": {
3027
"registry": "https://registry.npmjs.org"
3128
},
@@ -61,6 +58,5 @@
6158
"tokenRef": "GITHUB_AUTH"
6259
},
6360
"npm": false
64-
},
65-
"packageManager": "[email protected]"
61+
}
6662
}

0 commit comments

Comments
 (0)