modules.services.keyd: init

This commit is contained in:
陈浩南 2024-10-15 22:36:24 +08:00
parent ec49dcf5b9
commit 84451440f2
2 changed files with 22 additions and 0 deletions

View File

@ -142,6 +142,7 @@ inputs:
waydroid = {};
docker = {};
ananicy = {};
keyd = {};
};
bugs = [ "xmunet" "backlight" "amdpstate" "plasma" ];
};

21
modules/services/keyd.nix Normal file
View File

@ -0,0 +1,21 @@
inputs:
{
options.nixos.services.keyd = let inherit (inputs.lib) mkOption types; in mkOption
{ type = types.nullOr (types.submodule {}); default = null; };
config = let inherit (inputs.config.nixos.services) keyd; in inputs.lib.mkIf (keyd != null)
{
services.keyd =
{
enable = true;
keyboards.default =
{
ids = [ "*" ];
settings =
{
main.rightcontrol = "overload(r_ctrl, rightcontrol)";
"r_ctrl:C" = { left = "home"; right = "end"; up = "pageup"; down = "pagedown"; };
};
};
};
};
}