From ef4348bf682c6285e2404e515951a76cda62f482 Mon Sep 17 00:00:00 2001 From: Raboneko <119771935+raboneko@users.noreply.github.com> Date: Thu, 6 Feb 2025 00:38:58 -0800 Subject: [PATCH] add: fluent-kde-theme (#3207) (#3226) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add: fluent-kde-theme * update fluent-kde-theme license Co-authored-by: madomado Signed-off-by: Alberto García <4411661+GarciaLnk@users.noreply.github.com> --------- Signed-off-by: Alberto García <4411661+GarciaLnk@users.noreply.github.com> Co-authored-by: madomado (cherry picked from commit 73a539c5e701816f47c913b891f7bc6e0b7de46e) Co-authored-by: Alberto García <4411661+GarciaLnk@users.noreply.github.com> --- anda/themes/fluent-kde-theme/anda.hcl | 6 ++ .../fluent-kde-theme/fluent-kde-theme.spec | 57 +++++++++++++++++++ anda/themes/fluent-kde-theme/update.rhai | 5 ++ 3 files changed, 68 insertions(+) create mode 100644 anda/themes/fluent-kde-theme/anda.hcl create mode 100644 anda/themes/fluent-kde-theme/fluent-kde-theme.spec create mode 100644 anda/themes/fluent-kde-theme/update.rhai diff --git a/anda/themes/fluent-kde-theme/anda.hcl b/anda/themes/fluent-kde-theme/anda.hcl new file mode 100644 index 0000000000..e84c1e24c1 --- /dev/null +++ b/anda/themes/fluent-kde-theme/anda.hcl @@ -0,0 +1,6 @@ +project "pkg" { + arches = ["x86_64"] + rpm { + spec = "fluent-kde-theme.spec" + } +} diff --git a/anda/themes/fluent-kde-theme/fluent-kde-theme.spec b/anda/themes/fluent-kde-theme/fluent-kde-theme.spec new file mode 100644 index 0000000000..673f0ef570 --- /dev/null +++ b/anda/themes/fluent-kde-theme/fluent-kde-theme.spec @@ -0,0 +1,57 @@ +%global commit 9d6b7d4733707c38f72e8a614528f1df591419f3 +%global commit_date 20240827 +%global shortcommit %(c=%{commit}; echo ${c:0:7}) + +Name: fluent-kde-theme +Version: %commit_date.%shortcommit +Release: 1%?dist +Summary: Fluent design theme for KDE + +License: GPL-3.0-only +URL: https://github.com/vinceliuice/Fluent-kde +Source0: %url/archive/%commit/Fluent-kde-%commit.tar.gz + +BuildArch: noarch +BuildRequires: fdupes + +%description +%summary + +%prep +%autosetup -n Fluent-kde-%{commit} + +%build + +%install +mkdir -p %{buildroot}%{_datadir}/aurorae +mkdir -p %{buildroot}%{_datadir}/color-schemes +mkdir -p %{buildroot}%{_datadir}/plasma/desktoptheme +mkdir -p %{buildroot}%{_datadir}/plasma/look-and-feel +mkdir -p %{buildroot}%{_datadir}/Kvantum +mkdir -p %{buildroot}%{_datadir}/wallpapers + +# Patch install.sh to use the buildroot destination directories +sed -i "s|^[[:space:]]*AURORAE_DIR=.*|AURORAE_DIR=%{buildroot}%{_datadir}/aurorae|" install.sh +sed -i "s|^[[:space:]]*SCHEMES_DIR=.*|SCHEMES_DIR=%{buildroot}%{_datadir}/color-schemes|" install.sh +sed -i "s|^[[:space:]]*PLASMA_DIR=.*|PLASMA_DIR=%{buildroot}%{_datadir}/plasma/desktoptheme|" install.sh +sed -i "s|^[[:space:]]*LOOKFEEL_DIR=.*|LOOKFEEL_DIR=%{buildroot}%{_datadir}/plasma/look-and-feel|" install.sh +sed -i "s|^[[:space:]]*KVANTUM_DIR=.*|KVANTUM_DIR=%{buildroot}%{_datadir}/Kvantum|" install.sh +sed -i "s|^[[:space:]]*WALLPAPER_DIR=.*|WALLPAPER_DIR=%{buildroot}%{_datadir}/wallpapers|" install.sh + +# Invoke the installer now that variables are patched +./install.sh + +%fdupes %buildroot%_datadir + +%files +%license LICENSE +%doc README.md +%{_datadir}/aurorae/Fluent*/ +%{_datadir}/color-schemes/Fluent*.colors +%{_datadir}/plasma/desktoptheme/Fluent*/ +%{_datadir}/plasma/look-and-feel/com.github.vinceliuice.Fluent*/ +%{_datadir}/Kvantum/Fluent*/ +%{_datadir}/wallpapers/Fluent*/ + +%changelog +%autochangelog diff --git a/anda/themes/fluent-kde-theme/update.rhai b/anda/themes/fluent-kde-theme/update.rhai new file mode 100644 index 0000000000..cff10d5e14 --- /dev/null +++ b/anda/themes/fluent-kde-theme/update.rhai @@ -0,0 +1,5 @@ +rpm.global("commit", gh_commit("vinceliuice/Fluent-kde")); +if rpm.changed() { + rpm.release(); + rpm.global("commit_date", date()); +}