From db86c274f412d6ff7dbb0eb3b7da10c519824d8c Mon Sep 17 00:00:00 2001 From: Win_Update <3166832341@qq.com> Date: Mon, 30 Sep 2024 23:13:49 +0800 Subject: [PATCH] Update release.yml MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Modify the “Create tag” action in “release.yml” to solve the problem of not having access to the repository during process. --- .github/workflows/release.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index bcf757e..d572b4c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -57,9 +57,12 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 - name: Create tag - run: | - git tag ${{needs.build.outputs.version}} - git push origin ${{needs.build.outputs.version}} + uses: rickstaa/action-create-tag@v1 + id: "tag_create" + with: + tag: "${{needs.build.outputs.version}}" + tag_exists_error: true + message: "Created tag ${{needs.build.outputs.version}}" - name: Get repository name run: | echo "REPOSITORY_NAME=${GITHUB_REPOSITORY#${GITHUB_REPOSITORY_OWNER}/}" >> $GITHUB_ENV