nixpkgs/pkgs/data/misc/fedora-backgrounds/generic.nix
Alexis Hildebrandt 755b915a15 treewide: Remove indefinite article from meta.description
nix run nixpkgs#silver-searcher -- -G '\.nix$' -0l 'description.*"[Aa]n?' pkgs \
  | xargs -0 nix run nixpkgs#gnused -- -i '' -Ee 's/(description.*")[Aa]n? (.)/\1\U\2/'
2024-06-09 23:07:45 +02:00

49 lines
1.1 KiB
Nix

{ lib
, stdenvNoCC
, coreutils
}:
{ version
, src
, patches ? [ ]
}:
stdenvNoCC.mkDerivation {
inherit patches src version;
pname = "fedora${lib.versions.major version}-backgrounds";
dontBuild = true;
postPatch = ''
for f in default/Makefile extras/Makefile; do
substituteInPlace $f \
--replace "usr/share" "share" \
--replace "/usr/bin/" "" \
--replace "/bin/" ""
done
for f in $(find . -name '*.xml'); do
substituteInPlace $f \
--replace "/usr/share" "$out/share"
done;
'';
installFlags = [
"DESTDIR=$(out)"
# The Xfce background directory is assumed to be in installed in an
# FHS-compliant system. This is only effective for v36.0.0 and later
# versions where the following variable is used.
"WP_DIR_LN=$(DESTDIR)/share/backgrounds/$(WP_NAME)"
];
meta = with lib; {
homepage = "https://github.com/fedoradesign/backgrounds";
description = "Set of default and supplemental wallpapers for Fedora";
license = licenses.cc-by-sa-40;
platforms = platforms.unix;
maintainers = with maintainers; [ ];
};
}