about summary refs log tree commit diff
path: root/pkgs/by-name/_0/_0xpropo/package.nix
blob: 200e9758f778d083d87137fe01f006acc8f32353 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{
  lib,
  stdenvNoCC,
  fetchzip,
}:
stdenvNoCC.mkDerivation rec {
  pname = "0xpropo";
  version = "1.100";

  src = let
    underscoreVersion = builtins.replaceStrings ["."] ["_"] version;
  in
    fetchzip {
      url = "https://github.com/0xType/0xPropo/releases/download/${version}/0xPropo_${underscoreVersion}.zip";
      hash = "sha256-ZlZNvn9xiOxS+dfGI1rGbh6XlXo3/puAm2vhKh63sK4=";
    };

  installPhase = ''
    runHook preInstall
    install -Dm644 -t $out/share/fonts/opentype/ *.otf
    install -Dm644 -t $out/share/fonts/truetype/ *.ttf
    runHook postInstall
  '';

  meta = with lib; {
    description = "Proportional version of the 0xProto font";
    homepage = "https://github.com/0xType/0xPropo";
    changelog = "https://github.com/0xType/0xPropo/releases/tag/${version}";
    license = licenses.ofl;
    maintainers = with maintainers; [vinnymeller];
    platforms = platforms.all;
  };
}