From 61bc4abbc8bf25fcb9703ed37b19d88da933b2fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=23=E4=BA=91=E6=B7=A1=E7=84=B6?= Date: Wed, 15 Mar 2023 18:07:06 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20publish=20=E6=9D=A1=E4=BB=B6=205?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/release.yml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 48bda93..aea51a1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -19,18 +19,14 @@ jobs: token: ${{ secrets.GITHUB_TOKEN }} release-type: node bump-minor-pre-major: true - publish: - runs-on: ubuntu-latest - needs: release - if: needs.release.steps.release.outputs.release_created - steps: - uses: actions/checkout@v3 + if: ${{ steps.release.outputs.release_created }} - uses: actions/setup-node@v3 + if: ${{ steps.release.outputs.release_created }} with: node-version: 18 cache: npm - - run: npm ci - - run: npm run build - - run: npm publish + - run: npm ci && npm run build && npm publish + if: ${{ steps.release.outputs.release_created }} env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}