1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-17 19:21:04 +00:00

monocraft: 3.0 -> 4.0

This commit is contained in:
Coca 2024-08-11 01:26:10 +03:00
parent 5e0ca22929
commit 4fbc056449
No known key found for this signature in database
GPG key ID: 03282DF88179AB19

View file

@ -1,7 +1,7 @@
{ stdenvNoCC, lib, fetchurl }:
let
version = "3.0";
version = "4.0";
relArtifact = name: hash: fetchurl {
inherit name hash;
url = "https://github.com/IdreesInc/Monocraft/releases/download/v${version}/${name}";
@ -12,10 +12,9 @@ stdenvNoCC.mkDerivation {
inherit version;
srcs = [
(relArtifact "Monocraft.otf" "sha256-PA1W+gOUStGw7cDmtEbG+B6M+sAYr8cft+Ckxj5LciU=")
(relArtifact "Monocraft.ttf" "sha256-S4j5v2bTJbhujT3Bt8daNN1YGYYP8zVPf9XXjuR64+o=")
(relArtifact "Monocraft-no-ligatures.ttf" "sha256-MuHfoP+dsXe+ODN4vWFIj50jwOxYyIiS0dd1tzVxHts=")
(relArtifact "Monocraft-nerd-fonts-patched.ttf" "sha256-QxMp8UwcRjWySNHWoNeX2sX9teZ4+tCFj+DG41azsXw=")
(relArtifact "Monocraft.ttc" "sha256-SBzl/X2PQOq1cY4dlqO89BDwCrP+/LYwZ9X24p2LDCs=")
(relArtifact "Monocraft-no-ligatures.ttc" "sha256-jFZ5Fr/cBwGVsdy7lPqLiLlKtzjF5OIWVkwZI6gR3W4=")
(relArtifact "Monocraft-nerd-fonts-patched.ttc" "sha256-lYAb8hgmv4VyrzeHr4LnfuSN9L+4fpDEMX/P++fq8Dc=")
];
dontUnpack = true;
@ -24,8 +23,10 @@ stdenvNoCC.mkDerivation {
installPhase = ''
runHook preInstall
find $srcs -name '*.otf' -exec install -Dm644 --target $out/share/fonts/opentype {} +
find $srcs -name '*.ttf' -exec install -Dm644 --target $out/share/fonts/truetype {} +
for src in "''${srcs[@]}"
do
install -Dm644 --target $out/share/fonts/truetype $src
done
runHook postInstall
'';