From 53111332b6bb21cd42f9c037f44df1be6c126f99 Mon Sep 17 00:00:00 2001 From: Andy Kenward Date: Sat, 5 Jul 2025 14:39:15 +0000 Subject: [PATCH] ci: use cache more --- .github/workflows/check-dist.yml | 6 ++++++ .github/workflows/codeql.yml | 6 ++++++ .github/workflows/release.yml | 6 ++++++ .github/workflows/update.yml | 12 ++++++++++++ 4 files changed, 30 insertions(+) diff --git a/.github/workflows/check-dist.yml b/.github/workflows/check-dist.yml index 59076601..27d9b995 100644 --- a/.github/workflows/check-dist.yml +++ b/.github/workflows/check-dist.yml @@ -33,6 +33,12 @@ jobs: - uses: andykenward/github-actions/setup-pnpm@32471b1e0a5df8a09500a54b1254e3f0f881e52d #v1.0.3 with: node-version: 20 + - name: Cache + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 #v4.2.3 + with: + path: | + ~/.cache/ + key: ${{ runner.os }}-node-${{ hashFiles('**/pnpm-lock.yaml', '**/eslint.config.js', '**/prettier.config.cjs', '**/tsconfig.json', '**/knip.json', '**/vitest.config.ts', '**/vitest.setup.ts') }} - name: Rebuild the dist/ directory run: pnpm run build diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 0278cb51..6efc7659 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -30,6 +30,12 @@ jobs: - uses: andykenward/github-actions/setup-pnpm@32471b1e0a5df8a09500a54b1254e3f0f881e52d #v1.0.3 with: node-version: 20 + - name: Cache + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 #v4.2.3 + with: + path: | + ~/.cache/ + key: ${{ runner.os }}-node-${{ hashFiles('**/pnpm-lock.yaml', '**/eslint.config.js', '**/prettier.config.cjs', '**/tsconfig.json', '**/knip.json', '**/vitest.config.ts', '**/vitest.setup.ts') }} - name: Rebuild the dist/ directory run: pnpm run build - name: Perform CodeQL Analysis diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c48f8ee5..48138b72 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -29,6 +29,12 @@ jobs: - uses: andykenward/github-actions/setup-pnpm@32471b1e0a5df8a09500a54b1254e3f0f881e52d #v1.0.3 with: node-version: 20 + - name: Cache + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 #v4.2.3 + with: + path: | + ~/.cache/ + key: ${{ runner.os }}-node-${{ hashFiles('**/pnpm-lock.yaml', '**/eslint.config.js', '**/prettier.config.cjs', '**/tsconfig.json', '**/knip.json', '**/vitest.config.ts', '**/vitest.setup.ts') }} - name: Create Release Pull Request id: changesets uses: changesets/action@e0145edc7d9d8679003495b11f87bd8ef63c0cba #v1.5.3 diff --git a/.github/workflows/update.yml b/.github/workflows/update.yml index 2a1789ec..67acac08 100644 --- a/.github/workflows/update.yml +++ b/.github/workflows/update.yml @@ -21,6 +21,12 @@ jobs: - uses: andykenward/github-actions/setup-pnpm@32471b1e0a5df8a09500a54b1254e3f0f881e52d #v1.0.3 with: node-version: 20 + - name: Cache + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 #v4.2.3 + with: + path: | + ~/.cache/ + key: ${{ runner.os }}-node-${{ hashFiles('**/pnpm-lock.yaml', '**/eslint.config.js', '**/prettier.config.cjs', '**/tsconfig.json', '**/knip.json', '**/vitest.config.ts', '**/vitest.setup.ts') }} - name: cli download payloads run: pnpm run download env: @@ -48,6 +54,12 @@ jobs: - uses: andykenward/github-actions/setup-pnpm@32471b1e0a5df8a09500a54b1254e3f0f881e52d #v1.0.3 with: node-version: 20 + - name: Cache + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 #v4.2.3 + with: + path: | + ~/.cache/ + key: ${{ runner.os }}-node-${{ hashFiles('**/pnpm-lock.yaml', '**/eslint.config.js', '**/prettier.config.cjs', '**/tsconfig.json', '**/knip.json', '**/vitest.config.ts', '**/vitest.setup.ts') }} - name: cli all run: pnpm run tsc:types - name: Create Pull Request