Skip to content

Commit 8ba2bb0

Browse files
committed
update pnpm workflow
1 parent 5d29e0c commit 8ba2bb0

File tree

1 file changed

+15
-14
lines changed

1 file changed

+15
-14
lines changed

.github/workflows/default.yml

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,24 +17,25 @@ jobs:
1717
with:
1818
fetch-depth: 1
1919

20-
- name: Cache pnpm modules
21-
uses: actions/cache@v2
20+
- uses: actions/setup-node@v3
2221
with:
23-
path: ~/.pnpm-store
24-
key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }}
25-
restore-keys: |
26-
${{ runner.os }}-
22+
node-version: ${{ matrix.node-version }}
2723

28-
- uses: pnpm/action-setup@v2.0.1
29-
with:
30-
version: 7
31-
run_install: |
32-
- recursive: true
33-
- args: [--frozen-lockfile, --strict-peer-dependencies]
24+
- name: Get pnpm store directory
25+
id: pnpm-cache
26+
run: |
27+
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)"
3428
35-
- uses: actions/setup-node@v3
29+
- uses: actions/cache@v3
30+
name: Setup pnpm cache
3631
with:
37-
node-version: ${{ matrix.node-version }}
32+
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
33+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
34+
restore-keys: |
35+
${{ runner.os }}-pnpm-store-
36+
37+
- name: Install dependencies
38+
run: pnpm install --frozen-lockfile--strict-peer-dependencies
3839

3940
- name: Lint Source
4041
run: pnpm run --if-present lint

0 commit comments

Comments
 (0)