Skip to content

Commit

Permalink
Add workflow abort
Browse files Browse the repository at this point in the history
  • Loading branch information
GlacierWalrus committed Jun 24, 2024
1 parent 3def868 commit b5675db
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/workflows/publish_tagged.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
- name: Validate drand binary version matches git tag for this release
shell: bash
run: |
set -xeou pipefail
set -eou pipefail
drand_version=$(docker run -t ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }} -v | awk '{ print "v" $2 }')
# see https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string
tag_version=$(git describe --tags | grep -P \
Expand All @@ -48,8 +48,11 @@ jobs:
)
if [[ "$drand_version" != "$tag_version" ]]; then
>&2 echo "Error unexpected binary version $drand_version found on tag $tag_version"
gh run cancel ${{ github.run_id }}
exit 1
fi
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/setup-go@v5
with:
go-version: '1.22.1'
Expand Down

0 comments on commit b5675db

Please sign in to comment.