···11-{ ... }:
11+{ config, lib, ... }:
22+let
33+ cli-conf = lib.mkIf config.cli.enable {
44+ tmux.enable = lib.mkDefault true;
55+ };
66+ gui-conf = lib.mkIf config.gui.enable {
77+ };
88+in
99+{
1010+ imports = [
1111+ ./tmux.nix
1212+ ];
1313+1414+ options = {
1515+ cli = {
1616+ enable = lib.mkOption {
1717+ type = lib.types.bool;
1818+ description = ''
1919+ Can be used to enable all the default cli configs i got
2020+ '';
2121+ example = lib.literalExample true;
2222+ default = false;
2323+ };
2424+ };
2525+ gui = {
2626+ enable = lib.mkOption {
2727+ type = lib.types.bool;
2828+ description = ''
2929+ Can be used to enable all the default gui configs i got.
3030+ It also enable `default.cli`
3131+ '';
3232+ example = lib.literalExample true;
3333+ default = false;
3434+ };
3535+ };
3636+ };
23733-{
44- imports = [
55- ./tmux.nix
66- ];
3838+ config = lib.mkMerge [
3939+ cli-conf
4040+ gui-conf
4141+ (lib.mkIf config.gui.enable {
4242+ cli.enable = true;
4343+ })
4444+ ];
4545+746}
+1-1
modules/home-manager/tmux.nix
···1111 description = ''
1212 Can be used to enable my tmux config
1313 '';
1414- example = lib.literalExample "true";
1414+ example = lib.literalExample true;
1515 default = false;
1616 };
1717 };