Factor out default terminal and web browser

This commit is contained in:
Natsu Kagami 2025-01-15 21:42:55 +01:00
parent 076079aea1
commit 0a0e396ddf
Signed by: nki
GPG key ID: 55A032EB38B49ADB
6 changed files with 50 additions and 27 deletions

View file

@ -19,6 +19,11 @@ with lib;
options.nki.programs.kitty = {
enable = mkEnableOption "Enable kitty";
setDefault = mkOption {
type = types.bool;
description = "Set kitty as default terminal";
default = true;
};
package = mkOption {
type = types.package;
@ -51,6 +56,10 @@ with lib;
};
};
config.linux.graphical = mkIf (cfg.enable && cfg.setDefault) {
defaults.terminal.package = cfg.package;
};
config.programs.kitty = mkIf cfg.enable {
enable = true;