diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index 00863bd..d838764 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -24,17 +24,21 @@ jobs: uses: actions/setup-node@v4 with: node-version: 22 - - name: Get pnpm store directory - id: pnpm-store + - name: Get pnpm cache paths + id: pnpm-cache shell: bash - run: echo "dir=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT" - - name: Cache pnpm store + run: | + echo "store=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT" + echo "cache=$(pnpm cache path --silent)" >> "$GITHUB_OUTPUT" + - name: Cache pnpm store and metadata uses: actions/cache@v4 with: - path: ${{ steps.pnpm-store.outputs.dir }} - key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml') }} + path: | + ${{ steps.pnpm-cache.outputs.store }} + ${{ steps.pnpm-cache.outputs.cache }} + key: ${{ runner.os }}-pnpm-${{ hashFiles('pnpm-lock.yaml') }} restore-keys: | - ${{ runner.os }}-pnpm-store- + ${{ runner.os }}-pnpm- - name: Install Dependencies run: pnpm install --frozen-lockfile - name: Lint @@ -50,17 +54,21 @@ jobs: steps: - uses: builtin:checkout - uses: pnpm/action-setup@v4 - - name: Get pnpm store directory - id: pnpm-store + - name: Get pnpm cache paths + id: pnpm-cache shell: bash - run: echo "dir=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT" - - name: Cache pnpm store + run: | + echo "store=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT" + echo "cache=$(pnpm cache path --silent)" >> "$GITHUB_OUTPUT" + - name: Cache pnpm store and metadata uses: actions/cache@v4 with: - path: ${{ steps.pnpm-store.outputs.dir }} - key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml') }} + path: | + ${{ steps.pnpm-cache.outputs.store }} + ${{ steps.pnpm-cache.outputs.cache }} + key: ${{ runner.os }}-pnpm-${{ hashFiles('pnpm-lock.yaml') }} restore-keys: | - ${{ runner.os }}-pnpm-store- + ${{ runner.os }}-pnpm- - name: Install Dependencies run: pnpm install --frozen-lockfile - name: Run Tests