39 lines
788 B
Nix
39 lines
788 B
Nix
{
|
|
inputs,
|
|
pkgs,
|
|
lib,
|
|
config,
|
|
...
|
|
}:
|
|
let
|
|
cfg = config.modules.fonts;
|
|
in
|
|
{
|
|
options.modules.fonts = {
|
|
enable = lib.mkEnableOption "fonts";
|
|
};
|
|
config.fonts = lib.mkIf cfg.enable {
|
|
enableDefaultPackages = true;
|
|
packages =
|
|
with pkgs;
|
|
[
|
|
nerd-fonts.jetbrains-mono
|
|
material-design-icons
|
|
material-symbols
|
|
googlesans-code
|
|
nerd-fonts.caskaydia-cove
|
|
nerd-fonts.noto
|
|
noto-fonts-cjk-sans
|
|
noto-fonts-cjk-serif
|
|
]
|
|
++ [
|
|
(inputs.font-patcher.lib.patchFont {
|
|
font = "${pkgs.googlesans-code}/share/fonts/googlesans-code/GoogleSansCode[wght].ttf";
|
|
name = "Google Sans Code Nerd Font";
|
|
inherit system;
|
|
})
|
|
];
|
|
fontDir.enable = true;
|
|
};
|
|
}
|