Make Iosevka Aile optional due to resource-heavy compilation

This commit is contained in:
Erwin Boskma 2023-05-21 17:12:46 +02:00
parent b7dc99ee02
commit ac4fb1985e
Signed by: erwin
SSH key fingerprint: SHA256:9LmFDe1C6jSrEyqxxvX8NtJBmcbB105XoqyUZF092bg

View file

@ -89,7 +89,14 @@ with lib; let
};
in
{
options.eboskma.fonts = { enable = mkEnableOption "activate fonts"; };
options.eboskma.fonts = {
enable = mkEnableOption "activate fonts";
iosevka-aile = mkOption {
description = "Install Iosevka Aile";
type = types.bool;
default = true;
};
};
config = mkIf cfg.enable {
fonts = {
@ -100,19 +107,18 @@ in
corefonts
dejavu_fonts
google-fonts
iosevka-aile
kochi-substitute
material-icons
noto-fonts-emoji
recursive
ttf_bitstream_vera
twitter-color-emoji
];
] ++ lib.optional cfg.iosevka-aile iosevka-aile;
fontconfig = {
defaultFonts = {
serif = [ "Recursive Sans Casual Static Medium" ];
sansSerif = [ "Iosevka Aile" ];
sansSerif = [ (if cfg.iosevka-aile then "Iosevka Aile" else "DejaVu Sans") ];
monospace = [ "Iosevka Nerd Font" ];
emoji = [ "Twitter Color Emoji" ];
};