logitech (nixos): support module for logitech input devices

wip/yesman
Peter Hoeg 5 years ago
parent 86cff5f5d7
commit fe97297bb1
  1. 28
      nixos/modules/hardware/logitech.nix
  2. 1
      nixos/modules/module-list.nix

@ -0,0 +1,28 @@
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.hardware.logitech;
in {
options.hardware.logitech = {
enable = mkEnableOption "Logitech Devices";
enableGraphical = mkOption {
type = types.bool;
default = false;
description = "Enable graphical support applications.";
};
};
config = lib.mkIf cfg.enable {
environment.systemPackages = [
pkgs.ltunify
] ++ lib.optional cfg.enableGraphical pkgs.solaar;
# ltunifi and solaar both provide udev rules but the most up-to-date have been split
# out into a dedicated derivation
services.udev.packages = with pkgs; [ logitech-udev-rules ];
};
}

@ -45,6 +45,7 @@
./hardware/sensor/iio.nix
./hardware/ksm.nix
./hardware/ledger.nix
./hardware/logitech.nix
./hardware/mcelog.nix
./hardware/network/b43.nix
./hardware/nitrokey.nix

Loading…
Cancel
Save