2021-05-20 23:08:51 +00:00
|
|
|
{ lib, stdenv, fetchFromGitLab, glib, gnome, unzip }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "gnome-shell-extension-night-theme-switcher";
|
2021-10-28 06:52:43 +00:00
|
|
|
version = "53";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitLab {
|
|
|
|
owner = "rmnvgr";
|
|
|
|
repo = "nightthemeswitcher-gnome-shell-extension";
|
2021-10-28 06:52:43 +00:00
|
|
|
rev = version;
|
|
|
|
sha256 = "0dgnh1aj0y89jzfkpj8zs4gdbmyc1v8lbki2q30gld17ljv4l6lh";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-03-19 17:17:44 +00:00
|
|
|
nativeBuildInputs = [ unzip ];
|
2021-05-20 23:08:51 +00:00
|
|
|
buildInputs = [ glib gnome.gnome-shell ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-07-14 22:03:04 +00:00
|
|
|
passthru = {
|
|
|
|
extensionUuid = "nightthemeswitcher@romainvigier.fr";
|
|
|
|
extensionPortalSlug = "night-theme-switcher";
|
|
|
|
};
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
2020-07-18 16:06:22 +00:00
|
|
|
runHook preInstall
|
2020-04-24 23:36:52 +00:00
|
|
|
mkdir -p $out/share/gnome-shell/extensions/
|
2021-07-14 22:03:04 +00:00
|
|
|
unzip "build/nightthemeswitcher@romainvigier.fr.shell-extension.zip" -d "$out/share/gnome-shell/extensions/nightthemeswitcher@romainvigier.fr"
|
2020-07-18 16:06:22 +00:00
|
|
|
runHook postInstall
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Automatically change the GTK theme to dark variant when Night Light activates";
|
2021-06-28 23:13:55 +00:00
|
|
|
license = licenses.gpl3Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = with maintainers; [ jonafato ];
|
|
|
|
homepage = "https://gitlab.com/rmnvgr/nightthemeswitcher-gnome-shell-extension/";
|
|
|
|
};
|
|
|
|
}
|