nixos/libftdi: Init module

By enabling this module, the ftdi system group is created and udev
rules from the libftdi package are enabled. Read-/Write access is
granted to the members of the ftdi group and to seat sessions.

Signed-off-by: Felix Singer <felixsinger@posteo.net>
This commit is contained in:
Felix Singer 2025-02-19 21:53:08 +01:00 committed by Bjørn Forsman
parent 31d026d97b
commit 9eac410097
2 changed files with 24 additions and 0 deletions

View file

@ -0,0 +1,23 @@
{
config,
lib,
pkgs,
...
}:
let
cfg = config.hardware.libftdi;
in
{
options.hardware.libftdi = {
enable = lib.mkEnableOption "udev rules for devices supported by libftdi";
package = lib.mkPackageOption pkgs "libftdi1" { };
};
config = lib.mkIf cfg.enable {
users.groups.ftdi = { };
services.udev.packages = [ cfg.package ];
};
meta.maintainers = with lib.maintainers; [ felixsinger ];
}

View file

@ -78,6 +78,7 @@
./hardware/keyboard/zsa.nix
./hardware/ksm.nix
./hardware/ledger.nix
./hardware/libftdi.nix
./hardware/logitech.nix
./hardware/mcelog.nix
./hardware/network/ath-user-regd.nix