2024-08-01 05:48:06 +00:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
lib,
|
|
|
|
pkgs,
|
|
|
|
namespace,
|
|
|
|
...
|
|
|
|
}: let
|
|
|
|
inherit (lib) mkEnableOption mkIf;
|
|
|
|
|
|
|
|
cfg = config.${namespace}.programs.kitty;
|
|
|
|
in {
|
|
|
|
options.${namespace}.programs.kitty = {
|
|
|
|
enable = mkEnableOption "kitty";
|
|
|
|
};
|
|
|
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
programs.kitty = {
|
|
|
|
enable = true;
|
2024-09-22 04:57:13 +00:00
|
|
|
# Set theme explicity instead of using catppuccin flake until relevant PR
|
|
|
|
# is merged.
|
|
|
|
#
|
|
|
|
# https://github.com/catppuccin/nix/pull/337
|
|
|
|
themeFile = "Catppuccin-Mocha";
|
2024-08-01 05:48:06 +00:00
|
|
|
font = {
|
|
|
|
size = 12;
|
|
|
|
package = pkgs.nerdfonts.override {fonts = ["Hack"];};
|
|
|
|
name = "Hack Nerd Font";
|
|
|
|
};
|
|
|
|
settings = {
|
|
|
|
background_opacity = "0.95";
|
|
|
|
};
|
2024-08-20 04:13:47 +00:00
|
|
|
keybindings = lib.mkMerge [
|
|
|
|
(lib.mkIf pkgs.stdenv.hostPlatform.isDarwin {
|
2024-08-22 23:55:26 +00:00
|
|
|
"cmd+=" = "change_font_size current +1.0";
|
|
|
|
"cmd+minus" = "change_font_size current -1.0";
|
2024-08-20 04:13:47 +00:00
|
|
|
"cmd+0" = "change_font_size current 0";
|
|
|
|
})
|
|
|
|
(lib.mkIf pkgs.stdenv.hostPlatform.isLinux {
|
2024-08-22 23:55:26 +00:00
|
|
|
"ctrl+=" = "change_font_size current +1.0";
|
|
|
|
"ctrl+minus" = "change_font_size current -1.0";
|
2024-08-20 04:13:47 +00:00
|
|
|
"ctrl+0" = "change_font_size current 0";
|
|
|
|
})
|
|
|
|
];
|
2024-08-01 05:48:06 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|