From 1cf5e110079d4dad62bdb33e154345d3e4656996 Mon Sep 17 00:00:00 2001
From: Argent77 <4519923+Argent77@users.noreply.github.com>
Date: Wed, 4 Dec 2024 22:07:08 +0100
Subject: [PATCH] Update CD workflow: Upload zip instead of jar asset

Missing zip asset prevented the Flathub build bot from auto-updating
the Linux package.
---
 .github/workflows/deploy.yml | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
index 9e3206d64..e166153f1 100644
--- a/.github/workflows/deploy.yml
+++ b/.github/workflows/deploy.yml
@@ -34,6 +34,7 @@ jobs:
         id: ni-build
         run: |
           ant -noinput -buildfile build.xml
+          zip -r NearInfinity.zip NearInfinity.jar
           echo "NI_VERSION=$(java -jar "NearInfinity.jar" -version 2>/dev/null | grep -Eo '[0-9]{8}')" >> "$GITHUB_OUTPUT"
 
       # Required internally to build the installer packages
@@ -48,9 +49,9 @@ jobs:
         uses: svenstaro/upload-release-action@2.9.0
         with:
           repo_token: ${{ secrets.GITHUB_TOKEN }}
-          file: NearInfinity.jar
+          file: NearInfinity.zip
           tag: ${{ github.ref || github.event.release.tag_name }}
-          asset_name: NearInfinity-${{ steps.ni-build.outputs.NI_VERSION }}.jar
+          asset_name: NearInfinity-${{ steps.ni-build.outputs.NI_VERSION }}.zip
           overwrite: true
 
   # Build and upload installer versions for Windows, macOS-x86_64 and macOS-arm64