i3: Reduce invalid binding warnings

This commit is contained in:
Geoffrey Frogeye 2024-03-09 19:01:27 +01:00
parent 14f7199d65
commit 2fa993ad2d
Signed by: geoffrey
GPG key ID: C72403E7F82E6AD8
2 changed files with 3 additions and 3 deletions

View file

@ -108,7 +108,7 @@ in
"${mod}+Shift+c" = "reload";
"${mod}+Shift+r" = "restart";
"${mod}+Shift+e" = "exit";
} // lib.mapAttrs' (k: v: lib.nameValuePair v.enter "mode ${v.name}") modes
} // lib.mapAttrs' (k: v: lib.nameValuePair v.enter "mode ${v.name}") (lib.filterAttrs (k: v: v.enter != null) modes)
// lib.attrsets.mergeAttrsList (forEachCardinal (c: {
# change focus
"${mod}+${c.vi}" = "focus ${c.container}; ${focus}";
@ -202,7 +202,7 @@ in
default = { };
};
enter = lib.mkOption {
type = lib.types.str;
type = lib.types.nullOr lib.types.str;
default = "${mod}+${config.mod_enter}";
};
mod_enter = lib.mkOption {

View file

@ -20,7 +20,7 @@ in
return_bindings = false;
};
"${mode_pres_sec}" = {
mod_enter = "Shift+p+2"; # Bogus, just so I don't have to implement no binding
enter = null;
bindings = {
"b" = "workspace 1, workspace 2, mode ${mode_pres_main}";
"q" = "mode default";