install my own fonts to the nix store

This commit is contained in:
Christoph Cullmann 2024-09-01 17:22:32 +02:00
parent 976017ac80
commit f640e44fd5
No known key found for this signature in database
3 changed files with 25 additions and 4 deletions

1
.gitignore vendored
View file

@ -1 +1,2 @@
/secret/
*.secret *.secret

View file

@ -0,0 +1,20 @@
{
stdenvNoCC,
lib,
}:
stdenvNoCC.mkDerivation {
pname = "cullmann-fonts";
version = "1.0";
src = /nix/data/nixos/secret/fonts;
installPhase = ''
mkdir -p $out/share/fonts/truetype/
cp -r $src/*.{ttf,otf} $out/share/fonts/truetype/
'';
meta = with lib; {
description = "Cullmann's Fonts";
homepage = "https://cullmann.io/";
platforms = platforms.all;
};
}

View file

@ -1,6 +1,7 @@
{ config, pkgs, ... }: { config, pkgs, ... }:
let let
impermanence = builtins.fetchTarball "https://github.com/nix-community/impermanence/archive/master.tar.gz"; impermanence = builtins.fetchTarball "https://github.com/nix-community/impermanence/archive/master.tar.gz";
cullmann-fonts = pkgs.callPackage "/nix/data/nixos/packages/cullmann-fonts.nix" {};
in in
{ {
# #
@ -411,9 +412,8 @@ in
# system fonts # system fonts
packages = with pkgs; [ packages = with pkgs; [
# Inter & Merriweather as main fonts # personal paid fonts
inter cullmann-fonts
merriweather
# font families with good unicode coverage as fallback # font families with good unicode coverage as fallback
noto-fonts noto-fonts