2022-01-25 03:21:06 +00:00
|
|
|
{ stdenvNoCC
|
|
|
|
, fetchFromGitHub
|
|
|
|
, lib
|
|
|
|
, gtk3
|
|
|
|
, jdupes
|
|
|
|
, nordzy-themes ? [ "all" ] # Override this to only install selected themes
|
|
|
|
}:
|
|
|
|
|
2022-07-14 12:49:19 +00:00
|
|
|
stdenvNoCC.mkDerivation rec {
|
2022-01-25 03:21:06 +00:00
|
|
|
pname = "nordzy-icon-theme";
|
2023-04-12 12:48:02 +00:00
|
|
|
version = "1.8.4";
|
2022-01-25 03:21:06 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "alvatip";
|
|
|
|
repo = "Nordzy-icon";
|
2022-07-14 12:49:19 +00:00
|
|
|
rev = version;
|
2023-04-12 12:48:02 +00:00
|
|
|
sha256 = "sha256-3Lv1jwvFjeKxtBmY1ZwgPBjz8xjbqDH5EcwsIb9Vy7g=";
|
2022-01-25 03:21:06 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# In the post patch phase we should first make sure to patch shebangs.
|
|
|
|
postPatch = ''
|
|
|
|
patchShebangs install.sh
|
|
|
|
'';
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
gtk3
|
|
|
|
jdupes
|
|
|
|
];
|
|
|
|
|
|
|
|
dontDropIconThemeCache = true;
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
name= ./install.sh --dest $out/share/icons \
|
|
|
|
${lib.optionalString (nordzy-themes != []) (lib.strings.concatMapStrings (theme: "-t ${theme} ") nordzy-themes)}
|
|
|
|
|
|
|
|
# Replace duplicate files with hardlinks to the first file in each
|
|
|
|
# set of duplicates, reducing the installed size in about 87%
|
|
|
|
jdupes -L -r $out/share
|
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
|
|
|
dontFixup = true;
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Icon theme using the Nord color palette, based on WhiteSur and Numix icon themes";
|
|
|
|
homepage = "https://github.com/alvatip/Nordzy-icon";
|
|
|
|
license = licenses.gpl3Only;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ alexnortung ];
|
|
|
|
};
|
|
|
|
}
|