Advertisement
Guest User

Untitled

a guest
Feb 23rd, 2017
173
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.11 KB | None | 0 0
  1. { pkgs, ... }:
  2.  
  3. {
  4. environment.systemPackages = with pkgs; [
  5. pkgs.steamcontroller-udev-rules
  6. ];
  7.  
  8. nixpkgs.config.packageOverrides = pkgs: {
  9. steamcontroller-udev-rules = pkgs.writeTextFile {
  10. name = "steamcontroller-udev-rules";
  11. text = ''
  12. # This rule is needed for basic functionality of the controller in
  13. # Steam and keyboard/mouse emulation
  14. SUBSYSTEM=="usb", ATTRS{idVendor}=="28de", MODE="0666"
  15. # This rule is necessary for gamepad emulation; make sure you
  16. # replace 'pgriffais' with the username of the user that runs Steam
  17. KERNEL=="uinput", MODE="0660", GROUP="wheel", OPTIONS+="static_node=uinput"
  18. # systemd option not yet tested
  19. #KERNEL=="uinput", SUBSYSTEM=="misc", TAG+="uaccess", TAG+="udev-acl"
  20. # HTC Vive HID Sensor naming and permissioning
  21. KERNEL=="hidraw*", SUBSYSTEM=="hidraw", ATTRS{idVendor}=="0bb4", ATTRS{idProduct}=="2c87", MODE="0666"
  22. '';
  23. destination = "/etc/udev/rules.d/99-steamcontroller.rules";
  24. };
  25. };
  26.  
  27. services.udev.packages = [ pkgs.steamcontroller-udev-rules ];
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement