2022-03-23 13:10:18 +01:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
stdenv,
|
|
|
|
fetchFromGitHub,
|
2022-05-06 22:59:56 +02:00
|
|
|
gtk3,
|
|
|
|
breeze-icons,
|
|
|
|
hicolor-icon-theme,
|
2022-03-23 13:10:18 +01:00
|
|
|
hiDPI ? false,
|
|
|
|
}: let
|
2022-05-06 22:59:56 +02:00
|
|
|
name = "gruvbox-material-gtk";
|
|
|
|
rev = "cc255d43322ad646bb35924accb0778d5e959626";
|
|
|
|
sha256 = "1O34p9iZelqRFBloOSZkxV0Z/7Jffciptpj3fwXPHbc=";
|
|
|
|
|
2021-05-30 20:47:58 +02:00
|
|
|
variant =
|
2022-03-23 13:10:18 +01:00
|
|
|
if hiDPI
|
|
|
|
then "Gruvbox-Material-Dark-HIDPI"
|
|
|
|
else "Gruvbox-Material-Dark";
|
|
|
|
in
|
2022-05-06 22:59:56 +02:00
|
|
|
stdenv.mkDerivation {
|
|
|
|
pname = name;
|
|
|
|
version = rev;
|
2021-05-30 20:47:58 +02:00
|
|
|
|
2022-03-23 13:10:18 +01:00
|
|
|
src = fetchFromGitHub {
|
2022-05-06 22:59:56 +02:00
|
|
|
inherit rev sha256;
|
|
|
|
owner = "TheGreatMcPain";
|
|
|
|
repo = name;
|
2022-03-23 13:10:18 +01:00
|
|
|
};
|
2021-05-30 20:47:58 +02:00
|
|
|
|
2022-05-06 22:59:56 +02:00
|
|
|
nativeBuildInputs = [gtk3];
|
|
|
|
propagatedBuildInputs = [breeze-icons hicolor-icon-theme];
|
|
|
|
|
2022-03-23 13:10:18 +01:00
|
|
|
installPhase = ''
|
2022-05-06 22:59:56 +02:00
|
|
|
rm -rf README.md LICENSE demo.png
|
|
|
|
mkdir -p $out/share/themes/Gruvbox-Material-Dark
|
|
|
|
cp -r themes/${variant}/* $out/share/themes/Gruvbox-Material-Dark
|
|
|
|
mkdir -p $out/share/icons/Gruvbox-Material-Dark
|
|
|
|
cp -r icons/Gruvbox-Material-Dark/* $out/share/icons/Gruvbox-Material-Dark
|
|
|
|
gtk-update-icon-cache $out/share/icons/Gruvbox-Material-Dark
|
2022-03-23 13:10:18 +01:00
|
|
|
'';
|
2021-05-30 20:47:58 +02:00
|
|
|
|
2022-05-06 22:59:56 +02:00
|
|
|
dontDropIconThemeCache = true;
|
|
|
|
|
2022-03-23 13:10:18 +01:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Gruvbox Material for GTK";
|
2022-05-06 22:59:56 +02:00
|
|
|
homepage = "https://github.com/TheGreatMcPain/gruvbox-material-gtk";
|
2022-03-23 13:10:18 +01:00
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.unix;
|
|
|
|
maintainers = [];
|
|
|
|
};
|
|
|
|
}
|