Skip to content

Commit 9b03141

Browse files
Fix: Prevent zipping of Windows release executable
- The release workflow was failing on Windows because the `zip` command is not available on the default runner. - This change modifies the workflow to no longer package the Windows executable into a `.zip` archive. - The workflow now uploads the raw `.exe` for Windows and continues to upload `.zip` archives for macOS and Linux. - The artifact upload logic has been split into conditional steps for clarity and robustness, and artifact naming has been made consistent across all platforms.
1 parent c44bfa3 commit 9b03141

1 file changed

Lines changed: 10 additions & 2 deletions

File tree

.github/workflows/release.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,22 @@ jobs:
4040
shell: bash
4141
run: |
4242
if [ "${{ runner.os }}" == "Windows" ]; then
43-
zip -j dist/flashforge-emulator-windows.zip dist/flashforge-emulator.exe
43+
echo "Windows executable does not need packaging."
4444
elif [ "${{ runner.os }}" == "macOS" ]; then
4545
zip -j dist/flashforge-emulator-macos.zip dist/flashforge-emulator
4646
else
4747
zip -j dist/flashforge-emulator-linux.zip dist/flashforge-emulator
4848
fi
4949
50-
- name: Upload artifact
50+
- name: Upload Windows Artifact
51+
if: runner.os == 'Windows'
52+
uses: actions/upload-artifact@v4
53+
with:
54+
name: executables-${{ runner.os }}
55+
path: dist/flashforge-emulator.exe
56+
57+
- name: Upload Linux/macOS Artifact
58+
if: runner.os != 'Windows'
5159
uses: actions/upload-artifact@v4
5260
with:
5361
name: executables-${{ runner.os }}

0 commit comments

Comments
 (0)