From cb64c1061231ec5856f37b62460d2952d9587cf9 Mon Sep 17 00:00:00 2001 From: Bryce Kalow Date: Thu, 22 Aug 2024 15:17:22 -0500 Subject: [PATCH] fix(repo): Adjust npm cache (#4009) --- .changeset/gorgeous-lizards-give.md | 2 ++ .github/actions/init/action.yml | 24 +++--------------------- 2 files changed, 5 insertions(+), 21 deletions(-) create mode 100644 .changeset/gorgeous-lizards-give.md diff --git a/.changeset/gorgeous-lizards-give.md b/.changeset/gorgeous-lizards-give.md new file mode 100644 index 00000000000..a845151cc84 --- /dev/null +++ b/.changeset/gorgeous-lizards-give.md @@ -0,0 +1,2 @@ +--- +--- diff --git a/.github/actions/init/action.yml b/.github/actions/init/action.yml index 15022693d21..c05326f31c3 100644 --- a/.github/actions/init/action.yml +++ b/.github/actions/init/action.yml @@ -106,33 +106,15 @@ runs: - name: Setup NodeJS ${{ inputs.node-version }} uses: actions/setup-node@v4 with: + cache: npm + cache-dependency-path: '**/package-lock.json' node-version: ${{ inputs.node-version }} registry-url: ${{ inputs.registry-url }} - - name: NPM debug - shell: bash - run: npm config ls -l - - - name: Restore node_modules - uses: actions/cache/restore@v4 - id: cache-npm - with: - path: ./node_modules - key: ${{ runner.os }}-node-${{ inputs.node-version }}-node-modules-${{ hashFiles('**/package-lock.json') }}-v6 - restore-keys: ${{ runner.os }}-node-${{ inputs.node-version }}-node-modules- - - name: Install NPM Dependencies - # if: steps.cache-npm.outputs.cache-hit != 'true' - run: npm ci --prefer-offline --audit=false --fund=false --verbose + run: npm ci --audit=false --fund=false shell: bash - - name: Cache node_modules - uses: actions/cache/save@v4 - if: steps.cache-npm.outputs.cache-hit != 'true' - with: - path: ./node_modules - key: ${{ runner.os }}-node-${{ inputs.node-version }}-node-modules-${{ hashFiles('**/package-lock.json') }}-v6 - - name: Get Playwright Version if: inputs.playwright-enabled == 'true' shell: bash