From 8f80aca7fd64433d4b1c5d3ad473f7485570c334 Mon Sep 17 00:00:00 2001 From: denis0001-dev Date: Mon, 25 Aug 2025 12:59:40 +0300 Subject: [PATCH] Use npm cache --- .github/workflows/build.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 871ab08..7105da1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -33,6 +33,24 @@ jobs: with: node-version: '24' + - name: Cache npm (Linux/macOS) + if: runner.os != 'Windows' + uses: actions/cache@v4 + with: + path: ~/.npm + key: npm-${{ runner.os }}-node-24-${{ hashFiles('package.json') }} + restore-keys: | + npm-${{ runner.os }}-node-24- + + - name: Cache npm (Windows) + if: runner.os == 'Windows' + uses: actions/cache@v4 + with: + path: ~\AppData\Local\npm-cache + key: npm-${{ runner.os }}-node-24-${{ hashFiles('package.json') }} + restore-keys: | + npm-${{ runner.os }}-node-24- + - name: Install root deps (no scripts) run: npm install --ignore-scripts --no-audit --no-fund