Skip to content

Commit eb072a7

Browse files
committed
fix: fail wait job on timeout instead of proceeding
1 parent 4a438fc commit eb072a7

1 file changed

Lines changed: 0 additions & 24 deletions

File tree

.github/workflows/release.yml

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -5,35 +5,11 @@ on:
55
tags:
66
- 'v*'
77

8-
concurrency:
9-
group: release-${{ github.ref }}
10-
cancel-in-progress: false
11-
128
permissions:
139
contents: write
1410
id-token: write
1511

1612
jobs:
17-
wait:
18-
runs-on: ubuntu-latest
19-
steps:
20-
- name: Wait for GitHub Release
21-
env:
22-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23-
TAG: ${{ github.ref_name }}
24-
run: |
25-
echo "Waiting for release $TAG to exist..."
26-
for i in $(seq 1 30); do
27-
if gh release view "$TAG" &>/dev/null; then
28-
echo "Release $TAG found after ~${i}0 seconds"
29-
exit 0
30-
fi
31-
echo "Attempt $i/30: release not found yet, waiting 10s..."
32-
sleep 10
33-
done
34-
echo "::warning::Release $TAG not found after 5 minutes, proceeding anyway"
35-
3613
release:
37-
needs: wait
3814
uses: thedavidweng/cli-workflow-template/.github/workflows/go-release.yml@main
3915
secrets: inherit

0 commit comments

Comments
 (0)