2022-10-21 18:38:19 +00:00
|
|
|
{ lib, stdenv, fetchzip, xorg }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
pname = "profont";
|
|
|
|
version = "2019-11";
|
|
|
|
|
|
|
|
# Note: stripRoot doesn't work because the archive
|
2022-12-28 21:21:41 +00:00
|
|
|
# contains the metadata directory `__MACOSX`.
|
2020-04-24 23:36:52 +00:00
|
|
|
src = fetchzip {
|
|
|
|
url = "https://tobiasjung.name/downloadfile.php?file=profont-x11.zip";
|
|
|
|
sha256 = "12dbm87wvcpmn7nzgzwlk45cybp091diara8blqm6129ps27z6kb";
|
|
|
|
stripRoot = false;
|
|
|
|
} + /profont-x11;
|
|
|
|
|
|
|
|
srcOtb = fetchzip {
|
|
|
|
url = "https://tobiasjung.name/downloadfile.php?file=profont-otb.zip";
|
|
|
|
sha256 = "18rfhfqrsj3510by0w1a7ak5as6r2cxh8xv02xc1y30mfa6g24x6";
|
|
|
|
stripRoot = false;
|
|
|
|
} + /profont-otb;
|
|
|
|
|
|
|
|
dontBuild = true;
|
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
nativeBuildInputs = [ xorg.mkfontscale ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p "$out/share/fonts/misc"
|
|
|
|
for f in *.pcf; do
|
|
|
|
gzip -n -9 -c "$f" > "$out/share/fonts/misc/$f.gz"
|
|
|
|
done
|
|
|
|
install -D -m 644 LICENSE -t "$out/share/doc/$pname"
|
2020-09-25 04:45:31 +00:00
|
|
|
install -D -m 644 "$srcOtb/profontn.otb" -t $out/share/fonts/misc
|
2020-04-24 23:36:52 +00:00
|
|
|
mkfontdir "$out/share/fonts/misc"
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://tobiasjung.name/profont/";
|
|
|
|
description = "A monospaced font created to be a most readable font for programming";
|
|
|
|
maintainers = with maintainers; [ myrl ];
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|