feat(FN-4441): complete Step 1 — add node_modules cache layer

Fusion-Task-Id: FN-4441
Fusion-Task-Lineage: e3d7d9fe-cd8e-4c00-bb13-0fdb9ce91c34
This commit is contained in:
Fusion
2026-05-13 23:57:51 -07:00
committed by gsxdsm
parent 6ec7591270
commit 7ae3bc137a

View File

@@ -30,7 +30,20 @@ runs:
cache: pnpm
registry-url: ${{ inputs.registry-url }}
- name: Install dependencies
# Cache node_modules only for the exact pnpm-lock.yaml hash and Node/OS tuple.
# Intentionally no restore-keys fallback: partial restores can create inconsistent trees.
- name: Cache node_modules
id: node-modules-cache
if: ${{ inputs.skip-install != 'true' }}
uses: actions/cache@v4
with:
path: |
node_modules
**/node_modules
!**/.cache
key: node-modules-${{ runner.os }}-node${{ inputs.node-version }}-${{ hashFiles('pnpm-lock.yaml') }}
- name: Install dependencies
if: ${{ inputs.skip-install != 'true' && steps.node-modules-cache.outputs.cache-hit != 'true' }}
shell: bash
run: pnpm install ${{ inputs.install-args }}