mirror of
https://github.com/gburd/nix-config.git
synced 2024-11-20 10:36:25 +00:00
18 lines
368 B
Nix
18 lines
368 B
Nix
|
{ pkgs, username, ... }:
|
||
|
let
|
||
|
hidrawAccessGroup = "plugdev";
|
||
|
in
|
||
|
{
|
||
|
environment.systemPackages = with pkgs; [
|
||
|
roccat-tools
|
||
|
];
|
||
|
|
||
|
services.udev.extraRules = ''
|
||
|
KERNEL=="hidraw*", SUBSYSTEM=="hidraw", MODE="0660", GROUP="${hidrawAccessGroup}"
|
||
|
'';
|
||
|
|
||
|
users.groups.${hidrawAccessGroup} = { };
|
||
|
|
||
|
users.users.${username}.extraGroups = [ hidrawAccessGroup ];
|
||
|
}
|