fix: replace gitea.com release action with direct API upload

This commit is contained in:
2026-07-21 22:01:32 +02:00
parent f08a741708
commit 31b22fad68
+17 -14
View File
@@ -32,20 +32,23 @@ jobs:
# Create a zip file with all files required by the system to add to the release
- run: |
apt update -y
apt install -y zip
apt install -y zip jq
- run: zip -r ./fvtt-ecryme-${{github.event.release.tag_name}}.zip system.json README.md LICENSE.txt changelog.md css/ fonts/ images/ lang/ modules/ styles/ packs/ templates/ translated/ welcome-message-ecryme.html
- name: setup go
uses: https://github.com/actions/setup-go@v4
with:
go-version: ">=1.20.1"
- name: Use Go Action
id: use-go-action
uses: https://gitea.com/actions/release-action@main
with:
files: |-
./fvtt-ecryme-${{github.event.release.tag_name}}.zip
system.json
api_key: "${{secrets.ALLOW_PUSH_RELEASE}}"
- name: Upload release assets
env:
GITEA_TOKEN: ${{ secrets.ALLOW_PUSH_RELEASE }}
TAG_NAME: ${{ github.event.release.tag_name }}
REPO: ${{ gitea.repository }}
run: |
RELEASE_ID=$(curl -s -H "Authorization: token $GITEA_TOKEN" \
"https://www.uberwald.me/gitea/api/v1/repos/$REPO/releases/tags/$TAG_NAME" | jq -r '.id')
curl -s -H "Authorization: token $GITEA_TOKEN" \
-H "Content-Type: application/zip" \
--data-binary @./fvtt-ecryme-$TAG_NAME.zip \
"https://www.uberwald.me/gitea/api/v1/repos/$REPO/releases/$RELEASE_ID/assets?name=fvtt-ecryme-$TAG_NAME.zip"
curl -s -H "Authorization: token $GITEA_TOKEN" \
-H "Content-Type: application/json" \
--data-binary @./system.json \
"https://www.uberwald.me/gitea/api/v1/repos/$REPO/releases/$RELEASE_ID/assets?name=system.json"