nixos-config/packages/linja-nanpa.nix

23 lines
597 B
Nix
Raw Normal View History

2022-06-12 15:39:15 +00:00
{
stdenvNoCC,
fetchFromGitHub,
fontforge,
}:
2022-05-17 13:10:56 +00:00
stdenvNoCC.mkDerivation rec {
pname = "nasin-nanpa";
version = "2.5.18";
src = fetchFromGitHub {
owner = "ETBCOR";
repo = pname;
rev = "f464d17d992ce1d974983a54a25b57948d27e811";
sha256 = "sha256-zyKibrjvO5R0wbS2ocFRksJtrXjnW1I0gqkCAr/UZfc=";
};
2022-06-12 15:39:15 +00:00
nativeBuildInputs = [fontforge];
2022-05-17 13:10:56 +00:00
buildPhase = ''
fontforge -lang=ff -c 'Open($1); Generate($2)' "ffversions/2.5/nasin-nanpa-${version}.sfd" "nasin-nanpa.otf"
'';
installPhase = ''
install -m444 -Dt $out/share/fonts/opentype/nasin-nanpa nasin-nanpa.otf
'';
}