diff --git a/nixos/modules/hardware/inputmodule.nix b/nixos/modules/hardware/inputmodule.nix new file mode 100644 index 000000000000..a563de4006dd --- /dev/null +++ b/nixos/modules/hardware/inputmodule.nix @@ -0,0 +1,15 @@ +{ + config, + lib, + pkgs, + ... +}: + +{ + options.hardware.inputmodule.enable = lib.mkEnableOption ''Support for Framework input modules''; + + config = lib.mkIf config.hardware.inputmodule.enable { + environment.systemPackages = [ pkgs.inputmodule-control ]; + services.udev.packages = [ pkgs.inputmodule-control ]; + }; +} diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index 2f0e4fe6fbca..8a3e8b898a9a 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -71,6 +71,7 @@ ./hardware/hackrf.nix ./hardware/i2c.nix ./hardware/infiniband.nix + ./hardware/inputmodule.nix ./hardware/keyboard/qmk.nix ./hardware/keyboard/teck.nix ./hardware/keyboard/uhk.nix