From 6394d589dc716e45997c7a9f145aa8fc5a17189b Mon Sep 17 00:00:00 2001 From: XCWQW233 <3539757707@qq.com> Date: Fri, 16 Aug 2024 21:48:11 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=B7=A5=E4=BD=9C=E6=B5=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/release-build.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/release-build.yml b/.github/workflows/release-build.yml index e5d1a48..215dec7 100644 --- a/.github/workflows/release-build.yml +++ b/.github/workflows/release-build.yml @@ -15,6 +15,7 @@ jobs: uses: actions/checkout@v4 - name: '检查 tag' + shell: bash run: | git fetch --depth=1 origin +refs/tags/*:refs/tags/* tag_name="${GITHUB_REF##*/}" @@ -43,8 +44,8 @@ jobs: with: repo_token: ${{ secrets.GITHUB_TOKEN }} tag: ${{ env.TAG_NAME }} - file: dist/DDNetTool* - asset_name: DDNetToolBox-${{ runner.os }}-${{ env.TAG_NAME }}-* + file: dist/DDNetToolBox + asset_name: DDNetToolBox-${{ runner.os }}-${{ env.TAG_NAME }} prerelease: true build-windows: @@ -55,12 +56,13 @@ jobs: uses: actions/checkout@v4 - name: '检查 tag' + shell: pwsh run: | git fetch --depth=1 origin +refs/tags/*:refs/tags/* - tag_name="${GITHUB_REF##*/}" - echo Tag $tag_name + $tag_name = "${GITHUB_REF}".Split('/')[-1] + Write-Output "Tag $tag_name" git checkout $tag_name - echo "TAG_NAME=${tag_name}" >> $GITHUB_ENV + echo "TAG_NAME=$tag_name" >> $env:GITHUB_ENV - name: 初始化 Python ${{ env.PYTHON_VERSION }} 环境 uses: actions/setup-python@v4 @@ -83,6 +85,6 @@ jobs: with: repo_token: ${{ secrets.GITHUB_TOKEN }} tag: ${{ env.TAG_NAME }} - file: dist/DDNetTool* - asset_name: DDNetToolBox-${{ runner.os }}-${{ env.TAG_NAME }}-* + file: dist/DDNetToolBox.exe + asset_name: DDNetToolBox-${{ runner.os }}-${{ env.TAG_NAME }}.exe prerelease: true \ No newline at end of file