Merge pull request #329823 from ExpidusOS/fix/pkgsllvm/elfutils
[NixPkgs.git] / pkgs / by-name / ub / ubuntu-sans / package.nix
blobe85ee4333d6b05ade3dabb5c101aa68a47e9c826
2   lib,
3   stdenvNoCC,
4   fetchFromGitHub,
5   gitUpdater,
6   rename,
7 }:
9 stdenvNoCC.mkDerivation (finalAttrs: {
10   pname = "ubuntu-sans";
11   version = "1.004";
13   src = fetchFromGitHub {
14     owner = "canonical";
15     repo = "Ubuntu-Sans-fonts";
16     rev = "v${finalAttrs.version}";
17     hash = "sha256-TJHhRGBPDrYOAmOKyMaLcL2ugr4Bw2J6ErovglNx648=";
18   };
20   installPhase = ''
21     runHook preInstall
23     install -m444 -Dt $out/share/fonts/truetype/ubuntu-sans fonts/variable/*
24     ${rename}/bin/rename 's/\[.*\]//' $out/share/fonts/truetype/ubuntu-sans/*
26     runHook postInstall
27   '';
29   passthru.updateScript = gitUpdater { rev-prefix = "v"; };
31   meta = with lib; {
32     description = "Ubuntu Font Family";
33     longDescription = "The Ubuntu Font Family are a set of matching libre/open fonts.
34     The fonts were originally developed in 2010–2011,
35     further expanded and improved in 2015,
36     and expanded again in 2022–2023 when variable fonts were added.";
37     homepage = "https://design.ubuntu.com/font";
38     changelog = "https://github.com/canonical/Ubuntu-Sans-fonts/blob/${finalAttrs.src.rev}/FONTLOG.txt";
39     license = licenses.ufl;
40     platforms = platforms.all;
41     maintainers = with maintainers; [ jopejoe1 ];
42   };