Split documentation into each file
This commit is contained in:
parent
dfc4b5cf94
commit
4cd9e462d8
16 changed files with 205 additions and 187 deletions
31
modules/programs/xkb.nix
Normal file
31
modules/programs/xkb.nix
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
{
|
||||
lib,
|
||||
options,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
{
|
||||
options.mods.xkb = {
|
||||
layout = lib.mkOption {
|
||||
default = "dashie";
|
||||
example = "us";
|
||||
type = lib.types.str;
|
||||
description = "Your layout";
|
||||
};
|
||||
variant = lib.mkOption {
|
||||
default = "";
|
||||
example = "";
|
||||
type = lib.types.str;
|
||||
description = "Your variant";
|
||||
};
|
||||
};
|
||||
config = (
|
||||
lib.optionalAttrs (options ? services.xserver) {
|
||||
# Configure keymap in X11
|
||||
services.xserver = {
|
||||
xkb.layout = "${config.mods.xkb.layout}";
|
||||
xkb.variant = "${config.mods.xkb.variant}";
|
||||
};
|
||||
}
|
||||
);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue