From 0a06ecc41f35550545c931e54211bb97b04de41f Mon Sep 17 00:00:00 2001 From: Ingolf Wagner Date: Wed, 7 Jun 2023 15:31:47 +0200 Subject: [PATCH] add uhk --- nixos/components/gui/kmonad.nix | 6 ++++++ nixos/components/mainUser.nix | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/nixos/components/gui/kmonad.nix b/nixos/components/gui/kmonad.nix index 89ad530..816f063 100644 --- a/nixos/components/gui/kmonad.nix +++ b/nixos/components/gui/kmonad.nix @@ -8,6 +8,11 @@ config = lib.mkIf (config.components.gui.kmonad.enable) { + # only needed if you have an UHK + hardware.keyboard.uhk.enable = true; + environment.systemPackages = [ pkgs.uhk-agent ]; + users.users.mainUser.extraGroups = [ "input" ]; + services.xserver = { layout = "us"; xkbOptions = "compose:ralt"; @@ -57,6 +62,7 @@ { nativ = keyboard "/dev/input/by-path/platform-i8042-serio-0-event-kbd"; dasKeyboard = keyboard "/dev/input/by-id/usb-Metadot_-_Das_Keyboard_Das_Keyboard-event-kbd"; + uhk = keyboard "/dev/input/by-id/usb-Ultimate_Gadget_Laboratories_UHK_60_v2-if01-event-kbd"; }; }; }; diff --git a/nixos/components/mainUser.nix b/nixos/components/mainUser.nix index 6b26a31..32926a3 100644 --- a/nixos/components/mainUser.nix +++ b/nixos/components/mainUser.nix @@ -72,7 +72,7 @@ in uid = cfg.uid; home = "/home/${cfg.userName}"; initialPassword = cfg.userName; - extraGroups = [ "wheel" "networkmanager" "transmission" "wireshark" "audio" "pipewire" ] + extraGroups = [ "wheel" "networkmanager" "transmission" "wireshark" "audio" "pipewire" "input" ] ++ dockerGroup ++ vboxGroup ++ cfg.extraGroups; openssh.authorizedKeys.keyFiles = cfg.authorizedKeyFiles; group = config.users.groups.mainUser.name;