home: terminal: make 'default' extensible
This commit is contained in:
parent
14299fc6e8
commit
ea818e8584
3 changed files with 13 additions and 1 deletions
|
|
@ -4,6 +4,12 @@ let
|
||||||
inherit (config.my.home.terminal) colors;
|
inherit (config.my.home.terminal) colors;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
options.my.home.terminal = with lib; {
|
||||||
|
default = mkOption {
|
||||||
|
type = with types; nullOr (enum [ "alacritty" ]);
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
config = lib.mkIf (cfg.default == "alacritty") {
|
config = lib.mkIf (cfg.default == "alacritty") {
|
||||||
programs.alacritty = {
|
programs.alacritty = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ in
|
||||||
options.my.home = with lib; {
|
options.my.home = with lib; {
|
||||||
terminal = {
|
terminal = {
|
||||||
default = mkOption {
|
default = mkOption {
|
||||||
type = with types; nullOr (enum [ "alacritty" "termite" ]);
|
type = with types; nullOr (enum [ ]);
|
||||||
default = null;
|
default = null;
|
||||||
example = "termite";
|
example = "termite";
|
||||||
description = "Which default terminal to use for home session";
|
description = "Which default terminal to use for home session";
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,12 @@ let
|
||||||
inherit (config.my.home.terminal) colors;
|
inherit (config.my.home.terminal) colors;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
options.my.home.terminal = with lib; {
|
||||||
|
default = mkOption {
|
||||||
|
type = with types; nullOr (enum [ "termite" ]);
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
config = lib.mkIf (cfg.default == "termite") {
|
config = lib.mkIf (cfg.default == "termite") {
|
||||||
programs.termite = {
|
programs.termite = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue