Files
illogical-impulse/nix/modules/terminal/terminal.nix
T
2025-08-09 12:18:39 -05:00

69 lines
1.3 KiB
Nix

{
config,
lib,
pkgs,
...
}: let
inherit
(lib)
mkIf
mkMerge
mkDefault
mkOption
types
;
cfg = config.illogical-impulse.terminal;
commonTerminalConfig = {
environment.systemPackages = with pkgs; [
starship
eza
];
};
in {
options = {
illogical-impulse.terminal = {
enable = mkOption {
type = types.bool;
default = true;
description = ''
Whether to enable the terminal-related configuration for this user.
'';
};
terminalEmulator = mkOption {
type = types.enum ["foot" "kitty"];
default = "foot";
description = ''
The default terminal emulator to enable for this user.
'';
};
};
};
config = mkIf cfg.enable (
mkMerge [
commonTerminalConfig
(mkIf (cfg.terminalEmulator == "foot") {
programs.foot = {
enable = true;
# Foot-specific configuration
settings = {
main.font = "FiraCode Nerd Font:size=10";
};
};
})
(mkIf (cfg.terminalEmulator == "kitty") {
programs.kitty = {
enable = true;
settings = {
font_family = "FiraCode Nerd Font Mono";
font_size = 10.0;
};
};
})
]
);
}