feat(ci): base cache key on package-lock.json

This commit is contained in:
Timothy Stewart 2025-02-23 22:27:13 -06:00
parent cf1df9e6ed
commit a27d783451

View File

@ -21,12 +21,19 @@ jobs:
cache: 'npm'
cache-dependency-path: '**/package-lock.json'
- name: Cache NPM dependencies
uses: actions/cache@v4
with:
path: ~/.npm
key: npm-cache-${{ runner.os }}-${{ hashFiles('package-lock.json') }}
restore-keys: |
npm-cache-${{ runner.os }}-
- name: Install Dependencies and Build
run: |
npm ci
npx prisma generate
npm run build:prod
env:
CI: true
@ -35,4 +42,4 @@ jobs:
with:
path: ~/.npm/_npx
key: prisma-binary-${{ runner.os }}-${{ hashFiles('package-lock.json') }}
restore-keys: prisma-binary-${{ runner.os }}-
restore-keys: prisma-binary-${{ runner.os }}-