initial package for gnome-shell-extension-gpu-switcher-supergfxctl (#6917)

* initial package for gnome-shell-extension-gpu-switcher-supergfxctl

* add %doc README.md

* only build x86_64

Signed-off-by: Owen Zimmerman <123591347+Owen-sz@users.noreply.github.com>

* remove noarch

Signed-off-by: Owen Zimmerman <123591347+Owen-sz@users.noreply.github.com>

* for some reason it doesn't build unless it's noarch lol

Signed-off-by: Owen-sz <owen@fyralabs.com>

---------

Signed-off-by: Owen Zimmerman <123591347+Owen-sz@users.noreply.github.com>
Signed-off-by: Owen-sz <owen@fyralabs.com>
Co-authored-by: Owen Zimmerman <123591347+Owen-sz@users.noreply.github.com>
Co-authored-by: Owen-sz <owen@fyralabs.com>
This commit is contained in:
june
2025-11-05 00:16:49 -06:00
committed by GitHub
parent 0b4f4a79da
commit 2b6424fd55
3 changed files with 54 additions and 0 deletions
@@ -0,0 +1,6 @@
project pkg {
arches = ["x86_64"]
rpm {
spec = "gnome-shell-extension-gpu-supergfxctl-switch.spec"
}
}
@@ -0,0 +1,39 @@
%global commit 1de26db2ea4166fdca85306300b12bdc24f2c955
%global shortcommit %(c=%{commit}; echo ${c:0:7})
%global commit_date 20250925
%global ver 11
%global extension gpu-switcher-supergfxctl
%global uuid %{extension}@chikobara.github.io
Name: gnome-shell-extension-%{extension}
Version: %ver^%commit_date.%shortcommit
Release: 1%?dist
Summary: GPU Profile switcher Gnome-Shell-Extension for ASUS laptops using Supergfxctl
License: GPL-3.0-only
URL: https://github.com/chikobara/GPU-Switcher-Supergfxctl
Source0: %url/archive/%commit.tar.gz
Requires: (gnome-shell >= 48~ with gnome-shell < 50~) asusctl supergfxctl
Recommends: gnome-extensions-app
BuildArch: noarch
%description
GPU Profile switcher Gnome-Shell-Extension for ASUS laptops using Supergfxctl
%prep
%autosetup -n GPU-Switcher-Supergfxctl-%{commit} -p1
%install
install -Dm644 metadata.json %{buildroot}%{_datadir}/gnome-shell/extensions/%{uuid}/metadata.json
install -Dm644 extension.js %{buildroot}%{_datadir}/gnome-shell/extensions/%{uuid}/extension.js
%files
%license LICENSE
%doc README.md
%{_datadir}/gnome-shell/extensions/%{uuid}
%changelog
* Mon Oct 27 2025 june-fish <june@fyralabs.com> - 11
- Initial Package
@@ -0,0 +1,9 @@
if filters.contains("nightly") {
rpm.global("commit", gh_commit("chikobara/GPU-Switcher-Supergfxctl"));
if rpm.changed() {
let v = find("\"version\": ([.\\d]+)\n", gh_rawfile("chikobara/GPU-Switcher-Supergfxctl", "main", "metadata.json"), 1);
rpm.global("ver", v);
rpm.global("commit_date", date());
rpm.release();
}
}