From fa3fe9fdb25250379396c92edb430299bddb2d4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=89=8B=E7=93=9C=E4=B8=80=E5=8D=81=E9=9B=AA?= Date: Mon, 14 Sep 2026 11:43:29 +0800 Subject: [PATCH] Use pnpm setup in release workflow The release publishing workflow now installs pnpm via pnpm/action-setup instead of globally via npm, and applies the same improvement to the APIFox update job. This keeps the workflow consistent and avoids relying on the environment's global pnpm installation. --- .github/workflows/release-publish.yml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release-publish.yml b/.github/workflows/release-publish.yml index c75ae8b9..df1a7580 100644 --- a/.github/workflows/release-publish.yml +++ b/.github/workflows/release-publish.yml @@ -35,6 +35,11 @@ jobs: uses: actions/checkout@v5 with: ref: ${{ inputs.version }} + - name: Setup pnpm + uses: pnpm/action-setup@v4 + with: + version: 9 + run_install: false - name: Use Node.js 20.x uses: actions/setup-node@v6 with: @@ -43,7 +48,6 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - npm i -g pnpm pnpm i pnpm --filter napcat-webui-frontend run build || exit 1 pnpm run ${{ matrix.target.build_cmd }} @@ -414,11 +418,16 @@ jobs: NapCat.Shell.Windows.OneKey.zip draft: false + - name: Setup pnpm + uses: pnpm/action-setup@v4 + with: + version: 9 + run_install: false + - name: Update apifox env: APIFOX_TOKEN: ${{ secrets.APIFOX_TOKEN }} run: | - npm i -g pnpm pnpm i --ignore-scripts pnpm run build:openapi