simplify release workflow, switch AUR to versioned gpupaper package

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-06-08 21:23:49 +02:00
parent 3541618c84
commit 341384e54f
3 changed files with 29 additions and 60 deletions
+19 -42
View File
@@ -16,8 +16,6 @@ jobs:
include:
- arch: x86_64
target: x86_64-unknown-linux-gnu
- arch: aarch64
target: aarch64-unknown-linux-gnu
steps:
- uses: actions/checkout@v4
@@ -27,12 +25,6 @@ jobs:
sudo apt-get update
sudo apt-get install -y libwayland-dev pkg-config
- name: Install cross-compilation tools (aarch64 only)
if: matrix.arch == 'aarch64'
run: |
sudo apt-get install -y gcc-aarch64-linux-gnu
echo "CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc" >> $GITHUB_ENV
- name: Install Rust stable
uses: dtolnay/rust-toolchain@stable
with:
@@ -49,9 +41,9 @@ jobs:
- name: Package
run: |
VERSION="${{ gitea.ref_name }}"
TARBALL="gpupaper-${VERSION}-${{ matrix.arch }}.tar.gz"
mkdir -p pkg
TAG=${{ gitea.ref_name }}
TARBALL="gpupaper-${TAG}-${{ matrix.arch }}.tar.gz"
mkdir pkg
cp target/${{ matrix.target }}/release/gpupaper pkg/
cp -r shaders pkg/
cp LICENSE pkg/
@@ -59,41 +51,26 @@ jobs:
sha256sum "${TARBALL}" > "${TARBALL}.sha256"
echo "TARBALL=${TARBALL}" >> $GITHUB_ENV
# ---------------------------------------------------------------------------
# Upload to a PUBLIC Gitea repo used as a release mirror.
# Set RELEASE_REPO in repository secrets to "user/public-releases-repo".
# The token needs write access to that repo.
# ---------------------------------------------------------------------------
- name: Create release in mirror repo (if not already exists)
if: matrix.arch == 'x86_64'
- name: Create release
run: |
curl -sX POST \
-H "Authorization: token ${{ secrets.RELEASE_TOKEN }}" \
-H "Authorization: token ${{ secrets.GITEA_TOKEN }}" \
-H "Content-Type: application/json" \
"${{ gitea.server_url }}/api/v1/repos/${{ secrets.RELEASE_REPO }}/releases" \
-d "{\"tag_name\":\"${{ gitea.ref_name }}\",\"name\":\"${{ gitea.ref_name }}\",\"body\":\"\"}" \
--fail-with-body || true # ignore if release already exists
"${{ gitea.server_url }}/api/v1/repos/${{ gitea.repository }}/releases" \
-d "{\"tag_name\":\"${{ gitea.ref_name }}\",\"name\":\"${{ gitea.ref_name }}\"}" \
--fail-with-body || true
- name: Get release ID from mirror repo
- name: Upload assets
run: |
RELEASE_ID=$(curl -sX GET \
-H "Authorization: token ${{ secrets.RELEASE_TOKEN }}" \
"${{ gitea.server_url }}/api/v1/repos/${{ secrets.RELEASE_REPO }}/releases/tags/${{ gitea.ref_name }}" \
RELEASE_ID=$(curl -s \
-H "Authorization: token ${{ secrets.GITEA_TOKEN }}" \
"${{ gitea.server_url }}/api/v1/repos/${{ gitea.repository }}/releases/tags/${{ gitea.ref_name }}" \
| jq -r '.id')
echo "RELEASE_ID=${RELEASE_ID}" >> $GITHUB_ENV
- name: Upload binary asset
run: |
curl -sX POST \
-H "Authorization: token ${{ secrets.RELEASE_TOKEN }}" \
-H "Content-Type: application/octet-stream" \
"${{ gitea.server_url }}/api/v1/repos/${{ secrets.RELEASE_REPO }}/releases/${{ env.RELEASE_ID }}/assets?name=${{ env.TARBALL }}" \
--data-binary "@${{ env.TARBALL }}" --fail-with-body
- name: Upload checksum
run: |
curl -sX POST \
-H "Authorization: token ${{ secrets.RELEASE_TOKEN }}" \
-H "Content-Type: text/plain" \
"${{ gitea.server_url }}/api/v1/repos/${{ secrets.RELEASE_REPO }}/releases/${{ env.RELEASE_ID }}/assets?name=${{ env.TARBALL }}.sha256" \
--data-binary "@${{ env.TARBALL }}.sha256" --fail-with-body
for FILE in "${{ env.TARBALL }}" "${{ env.TARBALL }}.sha256"; do
curl -sX POST \
-H "Authorization: token ${{ secrets.GITEA_TOKEN }}" \
-H "Content-Type: application/octet-stream" \
"${{ gitea.server_url }}/api/v1/repos/${{ gitea.repository }}/releases/${RELEASE_ID}/assets?name=${FILE}" \
--data-binary "@${FILE}" --fail-with-body
done
+5 -8
View File
@@ -1,10 +1,9 @@
pkgbase = gpupaper-bin
pkgbase = gpupaper
pkgdesc = Wayland layer-surface wallpaper runner powered by GLSL/WGSL fragment shaders (wgpu)
pkgver = 0.1.0
pkgrel = 1
url = https://prosjekt.klingenbergbygg.no/bl/gpupaper
arch = x86_64
arch = aarch64
license = MIT
depends = wayland
depends = libglvnd
@@ -12,11 +11,9 @@ pkgbase = gpupaper-bin
optdepends = mesa: open-source Vulkan/OpenGL for AMD, Intel, and Raspberry Pi
optdepends = nvidia-utils: NVIDIA Vulkan/OpenGL support
provides = gpupaper
conflicts = gpupaper
conflicts = gpupaper-git
source_x86_64 = gpupaper-v0.1.0-x86_64.tar.gz::https://prosjekt.klingenbergbygg.no/bl/gpupaper-releases/releases/download/v0.1.0/gpupaper-v0.1.0-x86_64.tar.gz
sha256sums_x86_64 = SKIP
source_aarch64 = gpupaper-v0.1.0-aarch64.tar.gz::https://prosjekt.klingenbergbygg.no/bl/gpupaper-releases/releases/download/v0.1.0/gpupaper-v0.1.0-aarch64.tar.gz
sha256sums_aarch64 = SKIP
conflicts = gpupaper-bin
source = gpupaper-v0.1.0-x86_64.tar.gz::https://prosjekt.klingenbergbygg.no/bl/gpupaper/releases/download/v0.1.0/gpupaper-v0.1.0-x86_64.tar.gz
sha256sums = SKIP
pkgname = gpupaper-bin
pkgname = gpupaper
+5 -10
View File
@@ -1,9 +1,9 @@
# Maintainer: Bendik Aagaard Lynghaug <bendik.lynghaug@gmail.com>
pkgname=gpupaper-bin
pkgname=gpupaper
pkgver=0.1.0
pkgrel=1
pkgdesc="Wayland layer-surface wallpaper runner powered by GLSL/WGSL fragment shaders (wgpu)"
arch=('x86_64' 'aarch64')
arch=('x86_64')
url="https://prosjekt.klingenbergbygg.no/bl/gpupaper"
license=('MIT')
depends=('wayland' 'libglvnd')
@@ -13,14 +13,9 @@ optdepends=(
'nvidia-utils: NVIDIA Vulkan/OpenGL support'
)
provides=('gpupaper')
conflicts=('gpupaper' 'gpupaper-git')
# Update these URLs and checksums with each release.
# Binaries are hosted at: https://prosjekt.klingenbergbygg.no/bl/gpupaper-releases
source_x86_64=("gpupaper-v${pkgver}-x86_64.tar.gz::https://prosjekt.klingenbergbygg.no/bl/gpupaper-releases/releases/download/v${pkgver}/gpupaper-v${pkgver}-x86_64.tar.gz")
source_aarch64=("gpupaper-v${pkgver}-aarch64.tar.gz::https://prosjekt.klingenbergbygg.no/bl/gpupaper-releases/releases/download/v${pkgver}/gpupaper-v${pkgver}-aarch64.tar.gz")
sha256sums_x86_64=('SKIP')
sha256sums_aarch64=('SKIP')
conflicts=('gpupaper-git' 'gpupaper-bin')
source=("gpupaper-v${pkgver}-x86_64.tar.gz::https://prosjekt.klingenbergbygg.no/bl/gpupaper/releases/download/v${pkgver}/gpupaper-v${pkgver}-x86_64.tar.gz")
sha256sums=('SKIP')
package() {
install -Dm755 gpupaper "$pkgdir/usr/bin/gpupaper"