depot/third_party/nixpkgs/nixos/modules/services/hardware/bolt.nix
Default email c7cb07f092 Project import generated by Copybara.
GitOrigin-RevId: 1536926ef5621b09bba54035ae2bb6d806d72ac8
2024-02-29 21:09:43 +01:00

31 lines
689 B
Nix

{ config, lib, pkgs, ...}:
with lib;
let
cfg = config.services.hardware.bolt;
in
{
options = {
services.hardware.bolt = {
enable = mkOption {
type = types.bool;
default = false;
description = lib.mdDoc ''
Whether to enable Bolt, a userspace daemon to enable
security levels for Thunderbolt 3 on GNU/Linux.
Bolt is used by GNOME 3 to handle Thunderbolt settings.
'';
};
package = mkPackageOption pkgs "bolt" { };
};
};
config = mkIf cfg.enable {
environment.systemPackages = [ cfg.package ];
services.udev.packages = [ cfg.package ];
systemd.packages = [ cfg.package ];
};
}