Skip to content

Commit db6a02f

Browse files
committed
Improved caching
1 parent e944c3f commit db6a02f

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

.github/actions/install-dependencies/action.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,19 +12,20 @@ runs:
1212
with:
1313
version: 9
1414

15-
# Test
16-
1715
- name: Cache dependencies
1816
uses: actions/cache@v4
17+
id: cache
1918
with:
20-
path: node_modules
19+
path: |
20+
node_modules
21+
~/.pnpm-store
2122
# Generate a new cache whenever packages or source files change.
22-
key: ${{ runner.os }}-nestjs-${{ hashFiles('**/pnpm-lock.yaml') }}-${{ hashFiles('**.[jt]s', '**.[jt]sx') }}
23+
key: ${{ runner.os }}-nestjs-${{ hashFiles('**/pnpm-lock.yaml') }}
2324
# If source files changed but packages didn't, rebuild from a prior cache.
2425
restore-keys: |
25-
${{ runner.os }}-nestjs-${{ hashFiles('**/pnpm-lock.yaml') }}-
2626
${{ runner.os }}-nestjs-
2727
2828
- name: Install dependencies
29+
if: steps.cache.outputs.cache-hit != 'true'
2930
shell: bash
3031
run: pnpm install

0 commit comments

Comments
 (0)