fix: npm action

This commit is contained in:
nafees nazik
2024-01-05 01:58:00 +05:30
parent 634807328e
commit 75630ef19d

View File

@ -12,23 +12,28 @@ runs:
with:
node-version: ${{ inputs.node_version }}
- name: Cache node modules
id: cache-npm
- name: Cache npm
uses: actions/cache@v3
env:
cache-name: cache-node-modules
with:
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}
key: npm-${{ hashFiles('package-lock.json') }}
restore-keys: npm-
- name: Cache node_modules
uses: actions/cache@v3
id: cache-node-modules
with:
path: |
node_modules
packages/*/node_modules
apps/*/node_modules
key: modules-${{ hashFiles('package-lock.json') }}
- name: Install dependencies
if: steps.cache-node-modules.outputs.cache-hit != 'true'
shell: bash
run: |
npm ci
npm ci --no-audit
npm run prisma:generate
env:
HUSKY: '0'