nixpkgs/nixos/modules/services/hardware/bolt.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

32 lines
679 B
Nix
Raw Normal View History

2019-02-19 13:56:42 +00:00
{ config, lib, pkgs, ...}:
with lib;
let
cfg = config.services.hardware.bolt;
in
2019-02-19 13:56:42 +00:00
{
options = {
services.hardware.bolt = {
enable = mkOption {
type = types.bool;
default = false;
description = ''
2019-02-19 13:56:42 +00:00
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" { };
2019-02-19 13:56:42 +00:00
};
};
config = mkIf cfg.enable {
environment.systemPackages = [ cfg.package ];
services.udev.packages = [ cfg.package ];
systemd.packages = [ cfg.package ];
2019-02-19 13:56:42 +00:00
};
}