CI-CD: Fix gh release target

`gh release --target` no longer accepts a full ref
(and has never allowed a tag). It needs either
a branch or a sha.
This commit is contained in:
Mike Edmunds
2024-07-11 12:54:03 -07:00
parent f86c019e1d
commit 24031710ec

View File

@@ -76,7 +76,7 @@ jobs:
NOTES: |
[Changelog](https://anymail.dev/en/stable/changelog/#${{ steps.version.outputs.anchor }})
run: |
if ! gh release edit "$TAG" --verify-tag --target "$GITHUB_REF" --title "$TITLE" --notes "$NOTES"; then
gh release create "$TAG" --verify-tag --target "$GITHUB_REF" --title "$TITLE" --notes "$NOTES"
if ! gh release edit "$TAG" --verify-tag --target "$GITHUB_SHA" --title "$TITLE" --notes "$NOTES"; then
gh release create "$TAG" --verify-tag --target "$GITHUB_SHA" --title "$TITLE" --notes "$NOTES"
fi
gh release upload "$TAG" ./dist/*