Skip to content

Commit f268fd0

Browse files
authored
Merge pull request #1132 from ember-learn/pnpm
swap to pnpm
2 parents 13642e4 + e63ac0a commit f268fd0

File tree

8 files changed

+20659
-67554
lines changed

8 files changed

+20659
-67554
lines changed

.github/workflows/ci.yml

+23-38
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ on:
66
- main
77
pull_request:
88

9+
concurrency:
10+
group: ci-${{ github.head_ref || github.ref }}
11+
cancel-in-progress: true
12+
913
env:
1014
NODE_VERSION: 20
1115
PERCY_PARALLEL_NONCE: ${{ github.run_id }}-${{ github.run_number }}
@@ -17,42 +21,28 @@ jobs:
1721
runs-on: ubuntu-latest
1822
timeout-minutes: 3
1923
steps:
20-
- name: Check out a copy of the repo
21-
uses: actions/checkout@v2
22-
23-
- uses: mansona/npm-lockfile-version@v1
24-
25-
- name: Use Node.js ${{ env.NODE_VERSION }}
26-
uses: actions/setup-node@v2
24+
- uses: actions/checkout@v4
25+
- uses: pnpm/action-setup@v4
26+
- uses: actions/setup-node@v4
2727
with:
28-
cache: 'npm'
28+
cache: 'pnpm'
2929
node-version: ${{ env.NODE_VERSION }}
30-
31-
- name: Install dependencies
32-
run: npm ci
33-
34-
- name: Lint
35-
run: npm run lint
30+
- run: pnpm i --frozen-lockfile
31+
- run: pnpm run lint
3632

3733
test-app:
3834
name: Test app
3935
runs-on: ubuntu-latest
4036
timeout-minutes: 5
4137
steps:
42-
- name: Check out a copy of the repo
43-
uses: actions/checkout@v2
44-
45-
- name: Use Node.js ${{ env.NODE_VERSION }}
46-
uses: actions/setup-node@v2
38+
- uses: actions/checkout@v4
39+
- uses: pnpm/action-setup@v4
40+
- uses: actions/setup-node@v4
4741
with:
48-
cache: 'npm'
42+
cache: 'pnpm'
4943
node-version: ${{ env.NODE_VERSION }}
50-
51-
- name: Install dependencies
52-
run: npm ci
53-
54-
- name: Test
55-
run: npx percy exec -- npm run test
44+
- run: pnpm i --frozen-lockfile
45+
- run: pnpm percy exec -- npm run test
5646
env:
5747
PERCY_PARALLEL_NONCE: ${{ env.PERCY_PARALLEL_NONCE }}
5848
PERCY_PARALLEL_TOTAL: ${{ env.PERCY_PARALLEL_TOTAL }}
@@ -63,25 +53,20 @@ jobs:
6353
runs-on: ubuntu-latest
6454
timeout-minutes: 5
6555
steps:
66-
- name: Check out a copy of the repo
67-
uses: actions/checkout@v2
56+
- uses: actions/checkout@v4
6857
with:
6958
ref: ${{ github.event.pull_request.head.sha }}
70-
71-
- name: Use Node.js ${{ env.NODE_VERSION }}
72-
uses: actions/setup-node@v2
59+
- uses: pnpm/action-setup@v4
60+
- uses: actions/setup-node@v4
7361
with:
74-
cache: 'npm'
62+
cache: 'pnpm'
7563
node-version: ${{ env.NODE_VERSION }}
76-
77-
- name: Install dependencies
78-
run: npm ci
79-
64+
- run: pnpm i --frozen-lockfile
8065
- name: Build production app
81-
run: npm run build
66+
run: pnpm run build
8267

8368
- name: Run Lighthouse
84-
run: npx @lhci/[email protected] autorun
69+
run: pnpm lhci autorun
8570
env:
8671
LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }}
8772
LHCI_TOKEN: ${{ secrets.LHCI_TOKEN }}

.github/workflows/ember-assets.yml

+3-2
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,10 @@ jobs:
88
permissions:
99
pull-requests: write
1010
steps:
11-
- uses: actions/checkout@v3
11+
- uses: actions/checkout@v4
1212
with:
13-
fetch-depth: 0
13+
fetch-depth: 0
14+
- uses: pnpm/action-setup@v4
1415
- uses: mainmatter/ember-asset-size-action@v3
1516
with:
1617
repo-token: "${{ secrets.GITHUB_TOKEN }}"

.npmrc

+1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
ignore-scripts=false
2+
use-node-version=20.18.3

README.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ You will need the following things properly installed on your computer.
1919

2020
* `git clone <repository-url>` this repository
2121
* `cd ember-website`
22-
* `npm install`
22+
* `pnpm install`
2323

2424
## Running / Development
2525

26-
* `npm start`
26+
* `pnpm start`
2727
* Visit your app at [http://localhost:4200](http://localhost:4200).
2828
* Visit your tests at [http://localhost:4200/tests](http://localhost:4200/tests).
2929

@@ -33,17 +33,17 @@ Make use of the many generators for code, try `ember help generate` for more det
3333

3434
### Running Tests
3535

36-
* `npm test`
37-
* `npm test --server`
36+
* `pnpm test`
37+
* `pnpm test --server`
3838

3939
### Linting
4040

41-
* `npm run lint`
42-
* `npm run lint:fix`
41+
* `pnpm run lint`
42+
* `pnpm run lint:fix`
4343

4444
### Building
4545

46-
* `npm run build` (production)
46+
* `pnpm run build` (production)
4747

4848
### Deploying
4949

lib/content-data-generator/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* eslint-disable node/no-extraneous-require */
1+
/* eslint-disable node/no-extraneous-require, node/no-missing-require */
22
'use strict';
33

44
const BroccoliMergeTrees = require('broccoli-merge-trees');

0 commit comments

Comments
 (0)