We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3d2633a commit 9eb8608Copy full SHA for 9eb8608
.github/workflows/release.yml
@@ -41,7 +41,8 @@ jobs:
41
RELEASE_BRANCH="release/${TAG_NAME}"
42
43
# Check if branch exists on GitHub
44
- if gh api --silent --fail-silently repos/:owner/:repo/branches/$RELEASE_BRANCH; then
+ gh api repos/:owner/:repo/branches/$RELEASE_BRANCH >/dev/null 2>&1
45
+ if [ $? -eq 0 ]; then
46
echo "Branch exists on GitHub, deleting..."
47
gh api -X DELETE repos/:owner/:repo/git/refs/heads/$RELEASE_BRANCH
48
fi
0 commit comments