From b942f843bc71989d30a6cfbeaad5a86d9e0273e7 Mon Sep 17 00:00:00 2001 From: Sourabh Mehta Date: Wed, 10 Jan 2024 15:21:02 +0100 Subject: [PATCH 1/2] Run upload artifacts only when the tag is created --- .github/workflows/release.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index caf9d81..efa2e66 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -30,6 +30,7 @@ jobs: zip -r testreport.zip testreport - name: Attach coverage report to release assets + if: startsWith(github.ref, 'refs/tags/') uses: svenstaro/upload-release-action@v2 with: repo_token: ${{ secrets.GITHUB_TOKEN }} @@ -53,6 +54,7 @@ jobs: ./scripts/release_notes > /tmp/RELEASE_NOTES - name: Run GoReleaser + if: startsWith(github.ref, 'refs/tags/') uses: goreleaser/goreleaser-action@v5 with: version: latest From 896d7466b6b944009923108acc5d07481ebd7667 Mon Sep 17 00:00:00 2001 From: Sourabh Mehta <73165318+soumeh01@users.noreply.github.com> Date: Wed, 10 Jan 2024 16:58:19 +0100 Subject: [PATCH 2/2] Update release.yml --- .github/workflows/release.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index efa2e66..da91e3a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -54,7 +54,6 @@ jobs: ./scripts/release_notes > /tmp/RELEASE_NOTES - name: Run GoReleaser - if: startsWith(github.ref, 'refs/tags/') uses: goreleaser/goreleaser-action@v5 with: version: latest