et-book: use installFonts

Link: https://github.com/NixOS/nixpkgs/issues/495640

Signed-off-by: Ethan Carter Edwards <ethan@ethancedwards.com>
This commit is contained in:
Ethan Carter Edwards
2026-06-05 02:24:46 -07:00
parent ddb8b8028c
commit 2ca2094234

View File

@@ -2,12 +2,21 @@
lib,
stdenvNoCC,
fetchFromGitHub,
installFonts,
}:
stdenvNoCC.mkDerivation {
pname = "et-book";
version = "0-unstable-2015-10-05";
strictDeps = true;
__structuredAttrs = true;
outputs = [
"out"
"webfont"
];
src = fetchFromGitHub {
owner = "edwardtufte";
repo = "et-book";
@@ -15,14 +24,7 @@ stdenvNoCC.mkDerivation {
hash = "sha256-B6ryC9ibNop08TJC/w9LSHHwqV/81EezXsTUJFq8xpo=";
};
installPhase = ''
runHook preInstall
mkdir -p $out/share/fonts/truetype
cp -t $out/share/fonts/truetype source/4-ttf/*.ttf
runHook postInstall
'';
nativeBuildInputs = [ installFonts ];
meta = {
description = "Typeface used in Edward Tuftes books";