diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c4e85c6..e39ede3 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -15,6 +15,14 @@ jobs: with: node-version: "20" + - name: Cache npm + uses: actions/cache@v4 + with: + path: ~/.npm + key: ${{ runner.os }}-npm-cache-${{ hashFiles('**/package-lock.json') }} + restore-keys: | + ${{ runner.os }}-npm-cache- + - name: Install dependencies run: npm install diff --git a/.github/workflows/format.yaml b/.github/workflows/format.yaml index dff334b..952f5f6 100644 --- a/.github/workflows/format.yaml +++ b/.github/workflows/format.yaml @@ -15,8 +15,17 @@ jobs: with: node-version: "20" + - name: Cache npm + uses: actions/cache@v4 + with: + path: ~/.npm + key: ${{ runner.os }}-npm-cache-${{ hashFiles('**/package-lock.json') }} + restore-keys: | + ${{ runner.os }}-npm-cache- + - name: Install dependencies run: npm install - name: Run format check - run: npm run format + run: | + npm run format