Skip to content

Commit 67e8b70

Browse files
committed
feat(pipeline): Add clean-up job on Failure
1 parent 2435fbb commit 67e8b70

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

.github/workflows/buildRelease.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,3 +67,11 @@ jobs:
6767
PUBLISH_TOKEN: ${{ secrets.JETBRAINS_MARKETPLACE_TOKEN }}
6868
GRADLE_USER_HOME: /mnt/gradle-cache
6969
GRADLE_OPTS: "-Dorg.gradle.configuration-cache=false -Dorg.gradle.caching=false"
70+
71+
- name: Cleanup Tag on Failure
72+
if: failure()
73+
run: |
74+
echo "Build failed. Deleting tag v${{ steps.versions.outputs.TAGGED_VERSION }}..."
75+
git push --delete origin v${{ steps.versions.outputs.TAGGED_VERSION }}
76+
env:
77+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)