nixos-config/user/controller.nix

27 lines
623 B
Nix
Raw Normal View History

2024-05-30 21:48:43 -03:00
{ pkgs, lib, ... }:
{
2024-05-30 21:48:43 -03:00
systemd.user.services = {
autoconnect-gamepad = {
Unit = {
Description = "Attempt to connect to game controllers";
PartOf = [ "graphical-session.target" ];
After = [ "graphical-session.target" ];
};
Service = {
ExecStart = lib.getExe pkgs.auto_connect_gamepad;
};
Install = {
WantedBy = [ "sway-session.target" ];
};
2022-12-01 00:08:54 -03:00
};
2024-05-30 21:48:43 -03:00
};
xdg.desktopEntries = {
2022-12-01 00:08:54 -03:00
disconnect-controller = {
name = "Disconnect Controller";
exec = "bluetoothctl disconnect 84:30:95:97:1A:79";
terminal = false;
};
};
}