Skip to content

Commit be8fe81

Browse files
committed
Fix compression on Window runner
1 parent ad9190c commit be8fe81

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

.github/workflows/release.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,15 @@ jobs:
139139
mkdir -p release
140140
cp "target/${{ matrix.target }}/release/code-assistant${{ matrix.extension }}" release/
141141
cd release
142-
zip code-assistant-${{ matrix.name }}.zip "code-assistant${{ matrix.extension }}"
142+
143+
# Windows runner has no 'zip' installed
144+
if [ "${{ matrix.os }}" = "windows-latest" ]; then
145+
# PowerShell Compress-Archive instead of zip
146+
powershell -Command "Compress-Archive -Path ./code-assistant${{ matrix.extension }} -DestinationPath ./code-assistant-${{ matrix.name }}.zip"
147+
else
148+
# Linux/macOS: standard zip
149+
zip code-assistant-${{ matrix.name }}.zip "code-assistant${{ matrix.extension }}"
150+
fi
143151
144152
- name: Upload Release Asset
145153
uses: actions/upload-release-asset@v1

0 commit comments

Comments
 (0)