Files
nix/hosts/common/configs/user/gui/kitty/default.nix
Nikolaos Karaolidis 184aa4da8f Update
Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
2025-07-13 23:33:27 +01:00

49 lines
994 B
Nix

{ user, home }:
{
config,
lib,
pkgs,
...
}:
let
hmConfig = config.home-manager.users.${user};
in
{
environment.persistence."/persist/cache"."${home}/.cache/kitty" = { };
home-manager.users.${user} = {
programs.kitty = {
enable = true;
font = {
name = builtins.head hmConfig.theme.font.monospace.names;
package = builtins.head hmConfig.theme.font.monospace.packages;
inherit (hmConfig.theme.font) size;
};
settings = {
confirm_os_window_close = 0;
enable_audio_bell = false;
};
extraConfig = ''
include theme.conf
'';
};
theme = {
template.".config/kitty/theme.conf".source = ./theme.conf;
reloadExtraConfig = "${
lib.meta.getExe (
pkgs.writeShellApplication {
name = "reload-kitty";
runtimeInputs = with pkgs; [ procps ];
text = "exec pkill kitty -SIGUSR1";
}
)
} &";
};
};
}