about summary refs log tree commit diff
path: root/nixpkgs/pkgs/data/fonts/dm-sans/default.nix
blob: c2d8f33eff69f74d645e69181f4739efdd03267c (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
{ lib, stdenvNoCC, fetchzip }:

stdenvNoCC.mkDerivation rec {
  pname = "dm-sans";
  version = "1.002";

  src = fetchzip {
    url = "https://github.com/googlefonts/dm-fonts/releases/download/v${version}/DeepMindSans_v${version}.zip";
    stripRoot = false;
    hash = "sha256-RSHHxiCac18qqF+hW5M3BbBcra4AQpNLLlUmhiWj9f8=";
  };

  installPhase = ''
    runHook preInstall

    mkdir -p $out/share/fonts/truetype
    mv *.ttf $out/share/fonts/truetype

    runHook postInstall
  '';

  meta = {
    description = "A geometric sans-serif typeface";
    homepage = "https://github.com/googlefonts/dm-fonts";
    license = lib.licenses.ofl;
    maintainers = with lib.maintainers; [ gilice ];
  };
}