From e6f73f85044890fae23caf85abb6e303e55b63c8 Mon Sep 17 00:00:00 2001 From: Snoweuph Date: Wed, 5 Apr 2023 14:56:30 +0000 Subject: [PATCH] =?UTF-8?q?=E2=80=9E.gitea/workflows/build.yml=E2=80=9C=20?= =?UTF-8?q?=C3=A4ndern?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/build.yml | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml index f9b7c8f..e931561 100644 --- a/.gitea/workflows/build.yml +++ b/.gitea/workflows/build.yml @@ -31,11 +31,20 @@ jobs: - name: export for linux run: | mkdir -p ./builds/linux/ - /root/.local/share/godot/godot_executable/Godot_v4.0-stable_linux.x86_64 /var/lib/actions/project.godot --headless -q --export-release Linux/X11 ./builds/linux/Game.x86_64 + /root/.local/share/godot/godot_executable/Godot_v4.0-stable_linux.x86_64 /var/lib/actions/project.godot --headless -q --export-release "Linux/X11" ./builds/linux/Game.x86_64 - name: package for linux run: | cd builds tar -czvf linux.tar.gz -C linux/ . + - name: export for Windows + run: | + mkdir -p ./builds/windows/ + /root/.local/share/godot/godot_executable/Godot_v4.0-stable_linux.x86_64 /var/lib/actions/project.godot --headless -q --export-release "Windows Desktop" ./builds/windows/Game.exe + - name: package for windows + run: | + cd builds + cd windows; zip -r ../windows.zip * + cd .. - name: create release run: | echo "Getting last Release Tag" @@ -55,7 +64,7 @@ jobs: \"prerelease\": true, \"tag_name\": \"$VERSION\" }") - echo $ID + echo $ID Linux ID=$(echo $ID | jq -r '.id') echo "Uploading Build to Release" curl -X 'POST' \ @@ -64,3 +73,12 @@ jobs: -H 'Content-Type: multipart/form-data' \ -H 'Authorization: token ${{ secrets.RELEASE_TOKEN }}' \ -F 'attachment=@./builds/linux.tar.gz;type=application/gzip' + echo $ID Windows + ID=$(echo $ID | jq -r '.id') + echo "Uploading Build to Release" + curl -X 'POST' \ + "https://git.euph.dev/api/v1/repos/${{ github.repository }}/releases/$ID/assets?name=Windows.zip" \ + -H 'accept: application/json' \ + -H 'Content-Type: multipart/form-data' \ + -H 'Authorization: token ${{ secrets.RELEASE_TOKEN }}' \ + -F 'attachment=@./builds/windows.zip;type=application/gzip'