nixos/modules/hardware/default.nix

11 lines
435 B
Nix
Raw Normal View History

2023-07-15 22:45:35 +08:00
inputs:
{
options.nixos.hardware = let inherit (inputs.lib) mkOption types; in
{
bluetooth.enable = mkOption { type = types.bool; default = false; };
2023-07-15 22:48:24 +08:00
joystick.enable = mkOption { type = types.bool; default = false; };
2023-07-15 22:45:35 +08:00
};
2023-07-15 22:48:24 +08:00
config.hardware = { bluetooth.enable = inputs.config.nixos.hardware.bluetooth.enable; }
// (if inputs.config.nixos.hardware.joystick.enable then { xone.enable = true; xpadneo.enable = true; } else {});
2023-07-15 22:45:35 +08:00
}