{ lib, pkgs, config, ... }: let cfg = config.ptw.services.logiops; in { options.ptw.services.logiops = { enable = lib.mkEnableOption "Enable logiops"; }; config = lib.mkIf true { environment.etc."logid.conf".text = '' devices: ( { name: "Wireless Mouse MX Master 3"; hiresscroll: { hires: true; }; dpi: 800; } ); ''; systemd.services.logiops = { description = "An unofficial userspace driver for HID++ Logitech devices"; wantedBy = [ "default.target" ]; serviceConfig = { Type = "simple"; ExecStart = "${pkgs.logiops}/bin/logid"; }; }; }; }