From bf47e69fa4b3f720a213b9fd9b4fbf53450ac653 Mon Sep 17 00:00:00 2001 From: xiaoxia Date: Mon, 13 Jul 2026 15:10:44 +0800 Subject: [PATCH] feat(ci): add node_modules cache for frontend-lint job --- .gitea/workflows/ci-cd.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.gitea/workflows/ci-cd.yml b/.gitea/workflows/ci-cd.yml index 90caef5ae..a47d7ed29 100755 --- a/.gitea/workflows/ci-cd.yml +++ b/.gitea/workflows/ci-cd.yml @@ -192,6 +192,7 @@ jobs: frontend-lint: name: Frontend Lint runs-on: ubuntu-22.04 + timeout-minutes: 20 steps: - name: Checkout code @@ -217,7 +218,17 @@ jobs: tar -xzf /tmp/repo.tar.gz --strip-components=1 -C . rm -f /tmp/repo.tar.gz + - name: Cache node_modules + id: cache-node-modules + uses: actions/cache@v4 + with: + path: apps/web/node_modules + key: ${{ runner.os }}-node-web-${{ hashFiles('apps/web/package-lock.json') }} + restore-keys: | + ${{ runner.os }}-node-web- + - name: Install dependencies + if: steps.cache-node-modules.outputs.cache-hit != 'true' shell: sh run: | set -eu