feat(stylix): add enable option
This commit is contained in:
@@ -90,6 +90,7 @@
|
|||||||
redis.enable = true;
|
redis.enable = true;
|
||||||
};
|
};
|
||||||
k8s.enable = true;
|
k8s.enable = true;
|
||||||
|
my.stylix.enable = true;
|
||||||
git.github.enable = true;
|
git.github.enable = true;
|
||||||
git.gitlab.enable = true;
|
git.gitlab.enable = true;
|
||||||
secrets.vault.enable = true;
|
secrets.vault.enable = true;
|
||||||
|
|||||||
@@ -1,16 +1,21 @@
|
|||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
|
lib,
|
||||||
inputs,
|
inputs,
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
|
cfg = config.my.stylix;
|
||||||
theme = import ../../../modules/stylix/theme.nix { inherit pkgs; };
|
theme = import ../../../modules/stylix/theme.nix { inherit pkgs; };
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
imports = [ inputs.stylix.homeModules.stylix ];
|
imports = [ inputs.stylix.homeModules.stylix ];
|
||||||
|
|
||||||
|
options.my.stylix.enable = lib.mkEnableOption "stylix";
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
stylix = {
|
stylix = {
|
||||||
enable = true;
|
enable = true;
|
||||||
inherit (theme)
|
inherit (theme)
|
||||||
@@ -27,4 +32,5 @@ in
|
|||||||
};
|
};
|
||||||
targets = import ../../../modules/stylix/targets.nix;
|
targets = import ../../../modules/stylix/targets.nix;
|
||||||
};
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,16 +1,21 @@
|
|||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
inputs,
|
inputs,
|
||||||
|
lib,
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
|
cfg = config.my.stylix;
|
||||||
theme = import ./theme.nix { inherit pkgs; };
|
theme = import ./theme.nix { inherit pkgs; };
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
imports = [ inputs.stylix.nixosModules.stylix ];
|
imports = [ inputs.stylix.nixosModules.stylix ];
|
||||||
|
|
||||||
|
options.my.stylix.enable = lib.mkEnableOption "stylix theming";
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
stylix = {
|
stylix = {
|
||||||
enable = true;
|
enable = true;
|
||||||
inherit (theme)
|
inherit (theme)
|
||||||
@@ -33,4 +38,5 @@ in
|
|||||||
stylix.targets = import ./targets.nix;
|
stylix.targets = import ./targets.nix;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user