Skip to content

Commit 0639502

Browse files
committed
CI: Streamline and fix windows tool binary artifact creation
Instead of wrongly fixing up the .zip archive name in the prepare_release phase (and missing a space as per #9050), let the slint_tool_binary workflow create the correct .zip archive, then let upload-artifact archive the zip (instead of the directory), so that unpacking on the release job side will retain the zip file. This way it's handled the same as for .tar.gz (where download-artifact doesn't unarchive) and the file name is decided in one place (slint_tool_binary). Fixes #9050
1 parent e936ae5 commit 0639502

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

.github/workflows/nightly_snapshot.yaml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -591,18 +591,14 @@ jobs:
591591
mv slint-viewer-armv7-unknown-linux-gnueabihf.tar.gz artifacts/
592592
mv slint-viewer-aarch64-unknown-linux-gnu.tar.gz artifacts/
593593
mv slint-viewer-macos.tar.gz artifacts/
594+
mv slint-viewer-windows*.zip artifacts/
594595
mv slint-lsp-linux.tar.gz artifacts/
595596
mv slint-lsp-armv7-unknown-linux-gnueabihf.tar.gz artifacts/
596597
mv slint-lsp-aarch64-unknown-linux-gnu.tar.gz artifacts/
597598
mv slint-lsp-macos.tar.gz artifacts/
599+
mv slint-lsp-windows*.zip artifacts/
598600
mv slint-compiler-*.tar.gz artifacts/
599601
mv figma-plugin.zip artifacts/
600-
- uses: montudor/action-zip@v1
601-
with:
602-
args: zip -r artifacts/slint-viewer-windows-x86_64-pc-windows-msvc.zip slint-viewer
603-
- uses: montudor/action-zip@v1
604-
with:
605-
args: zip -r artifacts/slint-lsp-windowsx86_64-pc-windows-msvc.zip slint-lsp
606602
- uses: actions/checkout@v4
607603
with:
608604
path: "slint-src"

.github/workflows/slint_tool_binary.yaml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,13 +89,17 @@ jobs:
8989
cd ..
9090
cd tools\${{ github.event.inputs.program || inputs.program }}
9191
bash -x ../../scripts/prepare_binary_package.sh ..\..\pkg\slint-${{ github.event.inputs.program || inputs.program }}
92-
92+
- name: Create archive
93+
shell: powershell
94+
run: |
95+
cd pkg
96+
Compress-Archive -Path * -Destination ..\slint-${{ github.event.inputs.program || inputs.program }}-windows-${{ matrix.package_suffix }}.zip
9397
- name: Upload artifact
9498
uses: actions/upload-artifact@v4
9599
with:
96100
name: slint-${{ github.event.inputs.program || inputs.program }}-windows-${{ matrix.package_suffix }}
97101
path: |
98-
pkg
102+
slint-${{ github.event.inputs.program || inputs.program }}-windows-${{ matrix.package_suffix }}.zip
99103
100104
build_linux:
101105
runs-on: ubuntu-22.04

0 commit comments

Comments
 (0)