mirror of
https://github.com/renovatebot/renovate.git
synced 2025-01-11 22:46:27 +00:00
ci: fix cache keys (#29962)
This commit is contained in:
parent
6d01a1d73e
commit
174b1bf54e
1 changed files with 20 additions and 1 deletions
21
.github/actions/setup-node/action.yml
vendored
21
.github/actions/setup-node/action.yml
vendored
|
@ -47,6 +47,11 @@ runs:
|
|||
(steps.node-modules-restore.outputs.cache-hit == 'true') && 'true' || ''
|
||||
}}' >> "$GITHUB_ENV"
|
||||
|
||||
- name: Calculate `PNPM_STORE`
|
||||
shell: bash
|
||||
run: |
|
||||
echo "PNPM_STORE=$(pnpm store path)" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
|
||||
with:
|
||||
|
@ -56,7 +61,21 @@ runs:
|
|||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version: ${{ inputs.node-version }}
|
||||
cache: ${{ env.CACHE_HIT != 'true' && 'pnpm' || '' }}
|
||||
|
||||
- name: Cache and restore `pnpm store`
|
||||
if: env.CACHE_HIT != 'true'
|
||||
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
|
||||
with:
|
||||
path: ${{ env.PNPM_STORE }}
|
||||
key: |
|
||||
pnpm_store-${{
|
||||
inputs.os
|
||||
}}-${{
|
||||
inputs.node-version
|
||||
}}-${{
|
||||
hashFiles('pnpm-lock.yaml', 'package.json')
|
||||
}}
|
||||
enableCrossOsArchive: true
|
||||
|
||||
- name: Install dependencies
|
||||
uses: nick-fields/retry@7152eba30c6575329ac0576536151aca5a72780e # v3.0.0
|
||||
|
|
Loading…
Reference in a new issue