revert to softprops/action-gh-release with corrected artifact name
All checks were successful
Build Workflow / build (push) Successful in 6s

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-10 14:13:14 +01:00
parent 5fa079664f
commit c3e981cf06

View File

@@ -22,26 +22,9 @@ jobs:
VERSION=$(grep -A1 '<key>version</key>' info.plist | grep '<string>' | sed 's/.*<string>//;s/<\/string>.*//')
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
- name: Create release and upload artifact
env:
VERSION: v${{ steps.version.outputs.version }}
run: |
API="${GITHUB_SERVER_URL}/api/v1"
REPO="${GITHUB_REPOSITORY}"
AUTH="Authorization: token ${GITHUB_TOKEN}"
# delete existing release for this tag (idempotent)
EXISTING=$(curl -sf -H "$AUTH" "$API/repos/$REPO/releases/tags/$VERSION" | jq -r '.id // empty') || true
if [ -n "$EXISTING" ]; then
curl -sf -X DELETE -H "$AUTH" "$API/repos/$REPO/releases/$EXISTING"
fi
# create release
RELEASE_ID=$(curl -sf -X POST -H "$AUTH" -H "Content-Type: application/json" \
-d "{\"tag_name\":\"$VERSION\",\"name\":\"$VERSION\",\"body\":\"Automated build from main\"}" \
"$API/repos/$REPO/releases" | jq -r '.id')
# upload artifact
curl -sf -X POST -H "$AUTH" \
-F "attachment=@dist/tmux-cheat-sheet.alfredworkflow" \
"$API/repos/$REPO/releases/$RELEASE_ID/assets?name=tmux-cheat-sheet.alfredworkflow"
- name: Create release
uses: softprops/action-gh-release@v2
with:
tag_name: v${{ steps.version.outputs.version }}
name: v${{ steps.version.outputs.version }}
files: dist/tmux-cheat-sheet.alfredworkflow