Skip to content

Commit d0eb024

Browse files
committed
🔧 Tweak asset construction
1 parent c4755be commit d0eb024

1 file changed

Lines changed: 24 additions & 5 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,13 @@ on:
1414
jobs:
1515
compile-and-upload:
1616
name: Compile and Upload Plugin
17-
runs-on: ubuntu-latest
17+
runs-on: ${{ matrix.architecture }}
1818
strategy:
1919
matrix:
20-
ubuntu_version: ["25.10", "26.04"]
20+
version: ["25.04", "25.10", "26.04"]
21+
architecture: [ubuntu-latest, ubuntu-latest-arm]
2122
container:
22-
image: ghcr.io/kando-menu/kwin-dev-containers-${{ matrix.ubuntu_version }}:latest
23+
image: ghcr.io/kando-menu/kwin-dev-containers-${{ matrix.version }}:latest
2324
steps:
2425
- name: Checkout Repository
2526
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 #v6.0.3
@@ -36,14 +37,32 @@ jobs:
3637
|| dpkg-query -W -f='${Version}' kwin-dev 2>/dev/null \
3738
|| echo unknown)"
3839
VERSION="${VERSION%%-*}"
40+
VERSION="${VERSION#*:}"
3941
VERSION="${VERSION//[^0-9A-Za-z._-]/_}"
4042
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
43+
- name: Package Release Asset
44+
id: package_asset
45+
shell: bash
46+
run: |
47+
if [[ "${{ matrix.architecture }}" == "ubuntu-latest-arm" ]]; then
48+
ARCH_SUFFIX="arm"
49+
else
50+
ARCH_SUFFIX="x86"
51+
fi
52+
ASSET_NAME="kandointegration-for-kwin-${{ steps.kwin_version.outputs.version }}-${ARCH_SUFFIX}.zip"
53+
mkdir -p build/release-asset
54+
cp build/bin/kwin/effects/plugins/kandointegration.so build/release-asset/kandointegration.so
55+
(
56+
cd build/release-asset
57+
cmake -E tar cf "../${ASSET_NAME}" --format=zip kandointegration.so
58+
)
59+
echo "asset_name=${ASSET_NAME}" >> "$GITHUB_OUTPUT"
4160
- name: Upload Release
4261
uses: svenstaro/upload-release-action@29e53e917877a24fad85510ded594ab3c9ca12de #v2.11.5
4362
with:
4463
repo_token: ${{ secrets.GITHUB_TOKEN }}
45-
file: build/bin/kwin/effects/plugins/kandointegration.so
46-
asset_name: kandointegration-kwin-${{ steps.kwin_version.outputs.version }}.so
64+
file: build/${{ steps.package_asset.outputs.asset_name }}
65+
asset_name: ${{ steps.package_asset.outputs.asset_name }}
4766
tag: ${{ github.ref }}
4867
overwrite: true
4968
prerelease: true

0 commit comments

Comments
 (0)