From d2d5b53d83993d3acf63d2c68a4bb51526ec7d01 Mon Sep 17 00:00:00 2001 From: Molly Kan Date: Sun, 5 Jan 2025 23:01:31 +0800 Subject: [PATCH] change to pnpm --- .github/workflows/build-and-deploy.yml | 18 +++++++++++++++--- package.json | 4 +++- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-and-deploy.yml b/.github/workflows/build-and-deploy.yml index ae9f912..42fdabf 100644 --- a/.github/workflows/build-and-deploy.yml +++ b/.github/workflows/build-and-deploy.yml @@ -15,12 +15,24 @@ jobs: runs-on: ubuntu-latest steps: - name: checkout code repository - uses: actions/checkout@v2.3.1 + uses: actions/checkout@v4 + + - uses: pnpm/action-setup@v4 + name: Install pnpm + with: + version: 9 + run_install: false + + - name: Install Node.js + uses: actions/setup-node@v4 + with: + node-version: 20 + cache: 'pnpm' - name: Install and Build run: | - yarn install - yarn run build + pnpm install + pnpm run build - name: Deploy uses: JamesIves/github-pages-deploy-action@3.6.2 diff --git a/package.json b/package.json index 8d40cdc..dd169ea 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,9 @@ }, "devDependencies": { "vite": "^6.0.6", - "vite-plugin-pwa": "^0.21.1" + "vite-plugin-pwa": "^0.21.1", + "workbox-window": "^7.3.0", + "workbox-precaching": "^7.3.0" }, "dependencies": {} }