From 983f77c85636179fd86289180c7b006cd437d352 Mon Sep 17 00:00:00 2001 From: sea <45450994+warmthsea@users.noreply.github.com> Date: Fri, 21 Feb 2025 11:39:16 +0800 Subject: [PATCH] Update publish-pr-commit-pkg.yml --- .github/workflows/publish-pr-commit-pkg.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish-pr-commit-pkg.yml b/.github/workflows/publish-pr-commit-pkg.yml index 6edc9f846e..70898985c6 100644 --- a/.github/workflows/publish-pr-commit-pkg.yml +++ b/.github/workflows/publish-pr-commit-pkg.yml @@ -45,7 +45,14 @@ jobs: ls -la jq --arg newVersion "$LATEST_VERSION" '.version = $newVersion' package.json > tmp.json && mv tmp.json package.json - - name: Publish + - name: Publish for PR + if: ${{ github.event_name == 'pull_request' }} + run: | + cd dist/element-plus + pnpx pkg-pr-new publish + + - name: Publish for Commit Push + if: ${{ github.event_name == 'push' }} run: | cd dist/element-plus pnpx pkg-pr-new publish --comment=off