From 6a024aab010208995419a9ca69513a7a191bd0ca Mon Sep 17 00:00:00 2001 From: José Romildo Date: Fri, 27 Oct 2023 10:21:18 -0300 Subject: reversal-icon-theme: init at unstable-2023-05-13 --- pkgs/data/icons/reversal-icon-theme/default.nix | 77 +++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 ++ 2 files changed, 81 insertions(+) create mode 100644 pkgs/data/icons/reversal-icon-theme/default.nix diff --git a/pkgs/data/icons/reversal-icon-theme/default.nix b/pkgs/data/icons/reversal-icon-theme/default.nix new file mode 100644 index 00000000000..b636bba4a30 --- /dev/null +++ b/pkgs/data/icons/reversal-icon-theme/default.nix @@ -0,0 +1,77 @@ +{ lib +, stdenvNoCC +, fetchFromGitHub +, gtk3 +, jdupes +, adwaita-icon-theme +, hicolor-icon-theme +, numix-icon-theme-circle +, gitUpdater +, allColorVariants ? false +, colorVariants ? [] +}: + +let + pname = "reversal-icon-theme"; +in +lib.checkListOfEnum "${pname}: color variants" [ "-blue" "-red" "-pink" "-purple" "-green" "-orange" "-brown" "-grey" "-black" "-cyan" ] colorVariants + +stdenvNoCC.mkDerivation rec { + inherit pname; + version = "unstable-2023-05-13"; + + src = fetchFromGitHub { + owner = "yeyushengfan258"; + repo = pname; + rev = "bdae2ea365731b25a869fc2c8c6a1fb849eaf5b2"; + hash = "sha256-Cd+1ggyS+Y2Sk8w5zifc4IFOwbFrbjL6S6awES/W0EE="; + }; + + nativeBuildInputs = [ + gtk3 + jdupes + ]; + + propagatedBuildInputs = [ + adwaita-icon-theme + hicolor-icon-theme + numix-icon-theme-circle + ]; + + dontDropIconThemeCache = true; + + # These fixup steps are slow and unnecessary for this package. + # Package may install many small files. + dontPatchELF = true; + dontRewriteSymlinks = true; + + postPatch = '' + patchShebangs install.sh + ''; + + installPhase = '' + runHook preInstall + + mkdir -p $out/share/icons + + name= ./install.sh \ + ${if allColorVariants then "-a" else builtins.toString colorVariants} \ + -d $out/share/icons + + rm $out/share/icons/*/{AUTHORS,COPYING} + + jdupes --quiet --link-soft --recurse $out/share + + runHook postInstall + ''; + + passthru.updateScript = gitUpdater { }; + + meta = with lib; { + description = "A colorful Design Rectangle icon theme"; + homepage = "https://github.com/yeyushengfan258/Reversal-icon-theme"; + license = licenses.gpl3Plus; + platforms = platforms.all; + maintainers = with maintainers; [ romildo ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 26fd35bf312..2edecf8c63b 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -29996,6 +29996,10 @@ with pkgs; recursive = callPackage ../data/fonts/recursive { }; + reversal-icon-theme = callPackage ../data/icons/reversal-icon-theme { + inherit (gnome) adwaita-icon-theme; + }; + rubik = callPackage ../data/fonts/rubik { }; rhodium-libre = callPackage ../data/fonts/rhodium-libre { }; -- cgit 1.4.1