Skip to content

Commit 064792c

Browse files
committed
refactor: streamline GitHub Actions workflow by removing cache steps and using pnpm for dependency installation
1 parent 0dd38e8 commit 064792c

1 file changed

Lines changed: 14 additions & 13 deletions

File tree

.github/workflows/publish.yml

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -25,25 +25,26 @@ jobs:
2525
name: Build for GitHub Pages
2626
steps:
2727
- uses: actions/checkout@v3
28+
29+
- name: Setup pnpm
30+
uses: pnpm/action-setup@v4
31+
with:
32+
version: 9
33+
2834
- name: Setup node
29-
uses: actions/setup-node@v3
35+
uses: actions/setup-node@v4
3036
with:
31-
node-version: ^21.7.3
37+
node-version: ^22
38+
cache: 'pnpm'
3239

3340
- name: Setup Pages
3441
uses: actions/configure-pages@v5
3542

36-
- name: Restore cache
37-
uses: actions/cache@v4
38-
with:
39-
path: |
40-
.next/cache
41-
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json', '**/yarn.lock') }}-${{ hashFiles('**.[jt]s', '**.[jt]sx') }}
42-
restore-keys: |
43-
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json', '**/yarn.lock') }}-
44-
45-
- run: npm install
46-
- run: npm run build
43+
- name: Install dependencies
44+
run: pnpm install
45+
46+
- name: Build with Next.js
47+
run: pnpm run build
4748

4849
- name: Upload artifact
4950
uses: actions/upload-pages-artifact@v3

0 commit comments

Comments
 (0)