rearrange directory structure
This commit is contained in:
parent
2fe0f94a23
commit
67cb4995f9
33 changed files with 213 additions and 219 deletions
34
home/modules/menu.nix
Normal file
34
home/modules/menu.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.programs.menu;
|
||||
terminal = config.programs.terminal;
|
||||
termcmd = "${terminal}/bin/${terminal.pname}";
|
||||
in {
|
||||
options.programs = with lib; {
|
||||
menu = {
|
||||
package = mkPackageOption pkgs "wofi" {
|
||||
example = "pkgs.dmenu-wayland";
|
||||
};
|
||||
dmenuCommand = mkOption {
|
||||
default = "/bin/wofi --show dmenu";
|
||||
example = "/bin/dmenu";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
programs.wofi = lib.mkIf (cfg.package == pkgs.wofi) {
|
||||
enable = true;
|
||||
settings = {
|
||||
term = termcmd;
|
||||
insensitive = true;
|
||||
};
|
||||
};
|
||||
|
||||
home.packages = [cfg.package];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue