Skip to content

Commit 316ec9f

Browse files
authored
fix the double zipping of artifacts (#85)
Co-authored-by: Petr Gadorek <[email protected]>
1 parent 8e2e7ed commit 316ec9f

File tree

1 file changed

+7
-22
lines changed

1 file changed

+7
-22
lines changed

.github/workflows/build.yaml

Lines changed: 7 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -193,13 +193,6 @@ jobs:
193193
$perl_lib_path = "C:\hostedtoolcache\windows\perl\5.38.4-thr\x64\site\lib"
194194
echo "PERL5LIB=$perl_lib_path" >> $env:GITHUB_ENV
195195
196-
# - name: Install OpenSSL (Windows)
197-
# if: runner.os == 'Windows'
198-
# shell: powershell
199-
# run: |
200-
# echo "VCPKG_ROOT=$env:VCPKG_INSTALLATION_ROOT" >> $env:GITHUB_ENV
201-
# vcpkg install openssl:x64-windows-static-md
202-
203196
- name: Cache cargo
204197
uses: actions/cache@v4
205198
with:
@@ -299,23 +292,19 @@ jobs:
299292
xcrun notarytool submit eim.zip --keychain-profile "eim-notarytool-profile" --wait
300293
unzip -o eim.zip -d .
301294
302-
- name: Zip artifacts
303-
run: |
304-
cd release_cli/${{ matrix.package_name }}
305-
${{ runner.os == 'Windows' && '7z a -tzip eim.zip eim.exe' || 'zip -r eim.zip eim' }}
306295
307296
- name: Upload build artifacts
308297
uses: actions/upload-artifact@v4
309298
with:
310299
name: eim-cli-${{ matrix.package_name }}-${{ github.run_number }}
311-
path: release_cli/${{ matrix.package_name }}/eim.zip
300+
path: release_cli/${{ matrix.package_name }}/eim${{ runner.os == 'Windows' && '.exe' || '' }}
312301

313302
- name: Upload artifact for tag
314303
if: startsWith(github.ref, 'refs/tags/')
315304
uses: actions/upload-artifact@v4
316305
with:
317306
name: eim-cli-${{ matrix.package_name }}-${{ github.ref_name }}
318-
path: release_cli/${{ matrix.package_name }}/eim.zip
307+
path: release_cli/${{ matrix.package_name }}/eim${{ runner.os == 'Windows' && 'exe' || '' }}
319308

320309
- name: Upload Release Asset
321310
if: github.event_name == 'release' && github.event.action == 'created'
@@ -324,7 +313,7 @@ jobs:
324313
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
325314
with:
326315
upload_url: ${{ github.event.release.upload_url }}
327-
asset_path: release_cli/${{ matrix.package_name }}/eim.zip
316+
asset_path: release_cli/${{ matrix.package_name }}/eim${{ runner.os == 'Windows' && 'exe' || '' }}
328317
asset_name: eim-cli-${{ matrix.package_name }}-${{ github.ref_name }}.zip
329318
asset_content_type: application/zip
330319

@@ -418,23 +407,19 @@ jobs:
418407
run: |
419408
chmod +x src-tauri/target/release/eim
420409
chmod +x src-tauri/target/release/bundle/appimage/*.AppImage
421-
cd src-tauri/target/release
422-
zip -r eim.zip eim
423410
424411
- name: Handle macOS artifacts
425412
if: startsWith(matrix.os, 'macos')
426413
run: |
427414
chmod +x src-tauri/target/release/bundle/macos/eim.app
428-
cd src-tauri/target/release/bundle/macos
429-
zip -r eim.zip eim.app
430415
431416
- name: Upload Linux artifacts
432417
if: startsWith(matrix.os, 'ubuntu')
433418
uses: actions/upload-artifact@v4
434419
with:
435420
name: eim-gui-${{ matrix.package_name }}-${{ github.run_number }}
436421
path: |
437-
src-tauri/target/release/eim.zip
422+
src-tauri/target/release/eim
438423
# src-tauri/target/release/bundle/deb/*.deb
439424
# src-tauri/target/release/bundle/rpm/*.rpm
440425
# src-tauri/target/release/bundle/appimage/*.AppImage
@@ -446,7 +431,7 @@ jobs:
446431
with:
447432
name: eim-gui-${{ matrix.package_name }}-${{ github.run_number }}
448433
path: |
449-
src-tauri/target/release/bundle/macos/eim.zip
434+
src-tauri/target/release/eim
450435
# src-tauri/target/release/bundle/dmg/*.dmg
451436
# src-tauri/target/release/bundle/macos/*.app
452437
if-no-files-found: error
@@ -468,8 +453,8 @@ jobs:
468453
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
469454
with:
470455
upload_url: ${{ github.event.release.upload_url }}
471-
asset_path: ${{ runner.os == 'Windows' && 'src-tauri/target/release/eim.exe' || (startsWith(matrix.os, 'macos') && 'src-tauri/target/release/eim.zip' || 'src-tauri/target/release/bundle/macos/eim.zip') }}
472-
asset_name: eim-gui-${{ matrix.package_name }}.${{ runner.os == 'Windows' && 'exe' || 'zip' }}
456+
asset_path: ${{ runner.os == 'Windows' && 'src-tauri/target/release/eim.exe' || (startsWith(matrix.os, 'macos') && 'src-tauri/target/release/eim' || 'src-tauri/target/release/bundle/macos/eim') }}
457+
asset_name: eim-gui-${{ matrix.package_name }}.${{ runner.os == 'Windows' && 'exe' || '' }}
473458
asset_content_type: ${{ runner.os == 'Windows' && 'application/octet-stream' || 'application/zip' }}
474459

475460
test-cli:

0 commit comments

Comments
 (0)