From 2d65ee2ce6a7216850096d4f5197943e9337ddb1 Mon Sep 17 00:00:00 2001 From: Raboneko <119771935+raboneko@users.noreply.github.com> Date: Fri, 21 Feb 2025 15:18:50 -0800 Subject: [PATCH] add: astal (#3490) (#3495) (cherry picked from commit 54168cf91ed4646c3b03abe4e7cd4935ede8d256) Co-authored-by: madomado --- anda/lib/astal/astal/anda.hcl | 8 +++++ anda/lib/astal/astal/astal.spec | 62 ++++++++++++++++++++++++++++++++ anda/lib/astal/astal/update.rhai | 5 +++ andax/bump_extras.rhai | 13 +++++++ 4 files changed, 88 insertions(+) create mode 100644 anda/lib/astal/astal/anda.hcl create mode 100644 anda/lib/astal/astal/astal.spec create mode 100644 anda/lib/astal/astal/update.rhai diff --git a/anda/lib/astal/astal/anda.hcl b/anda/lib/astal/astal/anda.hcl new file mode 100644 index 0000000000..05e222653c --- /dev/null +++ b/anda/lib/astal/astal/anda.hcl @@ -0,0 +1,8 @@ +project pkg { + rpm { + spec = "astal.spec" + } + labels { + nightly = 1 + } +} diff --git a/anda/lib/astal/astal/astal.spec b/anda/lib/astal/astal/astal.spec new file mode 100644 index 0000000000..4cfb5a545c --- /dev/null +++ b/anda/lib/astal/astal/astal.spec @@ -0,0 +1,62 @@ + +%global commit 3620d51bc6c23ada1bd4b7c9cf1c458c138e68df +%global shortcommit %{sub %commit 1 7} +%global commit_date 20250222 + +Name: astal +Version: 0^%commit_date.%shortcommit +Release: 1%?dist +Summary: Building blocks for creating custom desktop shells +License: LGPL-2.1-only +URL: https://aylur.github.io/astal +Source0: https://github.com/Aylur/astal/archive/%commit.tar.gz +Provides: astal +Requires: %{name}-io-libs%{?_isa} = %{version}-%{release} +BuildRequires: meson gobject-introspection vala valadoc + +%description +The Linux Suite and Framework to Craft Desktop Shells and beautiful functional Wayland Widgets with GTK! + +%package io-libs +Summary: Shared libraries of libastal-io + +%description io-libs +%summary. (IO) + +This package contains shared libraries for astal-io. + +%package io-devel +Summary: Development libraries of libastal-io +Requires: %{name}-io-libs%{?_isa} = %{version}-%{release} + +%description io-devel +%summary. (IO) +This package contains development files and documentation for astal-io. + +%prep +%autosetup -n astal-%commit + +%build +cd lib/astal/io +%meson +%meson_build + +%install +cd lib/astal/io +%meson_install + +%files +%_bindir/astal + +%files io-libs +%license LICENSE +%_libdir/libastal-io.so.0 +%_libdir/libastal-io.so.0.1.0 + +%files io-devel +%_datadir/gir-1.0/AstalIO-0.1.gir +%_datadir/vala/vapi/astal-io-0.1.vapi +%_includedir/astal-io.h +%_libdir/girepository-1.0/AstalIO-0.1.typelib +%_libdir/libastal-io.so +%_libdir/pkgconfig/astal-io-0.1.pc diff --git a/anda/lib/astal/astal/update.rhai b/anda/lib/astal/astal/update.rhai new file mode 100644 index 0000000000..c68d29af82 --- /dev/null +++ b/anda/lib/astal/astal/update.rhai @@ -0,0 +1,5 @@ +rpm.global("commit", gh_commit("Aylur/astal")); +if rpm.changed() { + rpm.release(); + rpm.global("commit_date", date()); +} diff --git a/andax/bump_extras.rhai b/andax/bump_extras.rhai index c7c21db7b4..e11d7df448 100644 --- a/andax/bump_extras.rhai +++ b/andax/bump_extras.rhai @@ -20,3 +20,16 @@ fn bodhi(pkg, branch) { let url = `https://bodhi.fedoraproject.org/updates/?search=${pkg}&status=stable&releases=${branch}&rows_per_page=1&page=1`; return find(`^${pkg}-([\d.]+)-\d+\.[\w\d]+$`, get(url).json().updates[0].title, 1); } + + +fn madoguchi_json(pkg, branch) { + let branch = labels.branch; + if branch.starts_with("f") { + branch.crop(1); + } + return get(`https://madoguchi.fyralabs.com/v4/terra${branch}/packages/${pkg}`).json(); +} + +fn madoguchi(pkg, branch) { + return madoguchi_json(pkg, branch).ver; +}