nixpkgs/nixos/modules/hardware/xone.nix
Cryolitia PukNgae ef059726f1
nixos/xone: enable xpad-noone by default
Co-authored-by: misuzu <neironyan@gmail.com>
2025-04-29 22:38:48 +08:00

30 lines
591 B
Nix

{
config,
lib,
pkgs,
...
}:
let
cfg = config.hardware.xone;
in
{
options.hardware.xone = {
enable = lib.mkEnableOption "the xone driver for Xbox One and Xbox Series X|S accessories";
};
config = lib.mkIf cfg.enable {
boot = {
blacklistedKernelModules = [
"xpad"
"mt76x2u"
];
extraModulePackages = with config.boot.kernelPackages; [ xone ];
};
hardware.firmware = [ pkgs.xow_dongle-firmware ];
hardware.xpad-noone.enable = lib.mkDefault true;
};
meta = {
maintainers = with lib.maintainers; [ rhysmdnz ];
};
}