add extraConfigs option to quickshell module
This commit is contained in:
parent
e386a95e02
commit
2141534e48
1 changed files with 14 additions and 2 deletions
|
@ -7,9 +7,20 @@
|
|||
}: with lib; let
|
||||
cfg = config.myOptions.programs.quickshell;
|
||||
inherit (config.myOptions.other.system) username;
|
||||
|
||||
defaultConfigs = {
|
||||
powermenu = ./powermenu;
|
||||
poz = ./poz;
|
||||
};
|
||||
in {
|
||||
options.myOptions.programs.quickshell = {
|
||||
enable = mkEnableOption "quickshell";
|
||||
|
||||
extraConfigs = mkOption {
|
||||
description = "extra modules (no need to enable these)";
|
||||
type = with types; attrsOf path;
|
||||
default = {};
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
@ -21,8 +32,9 @@ in {
|
|||
];
|
||||
|
||||
xdg.configFile."quickshell/manifest.conf".text = ''
|
||||
powermenu = ${./powermenu}
|
||||
poz = ${./poz}
|
||||
${concatStrings (mapAttrsToList (name: value: ''
|
||||
${name} = ${value}
|
||||
'') defaultConfigs // cfg.extraConfigs)}
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue