Files
Jörg Thalheim 8b9171eed7 nixos/facter: add input peripheral detection
This adds automatic detection and configuration for input peripherals:

- bluetooth: Detects Bluetooth hardware and automatically enables
- fingerprint: Detects USB fingerprint devices using libfprint device database

Builds on PR #458177 (graphics).
Part of incremental upstreaming from nixos-facter-modules.
2025-12-01 13:48:46 +01:00

14 lines
419 B
Nix

{ lib, config, ... }:
{
options.hardware.facter.detected.bluetooth.enable =
lib.mkEnableOption "Enable the Facter bluetooth module"
// {
default = builtins.length (config.hardware.facter.report.hardware.bluetooth or [ ]) > 0;
defaultText = "hardware dependent";
};
config.hardware.bluetooth.enable = lib.mkIf config.hardware.facter.detected.bluetooth.enable (
lib.mkDefault true
);
}