1{
2 config,
3 lib,
4 pkgs,
5 ...
6}:
7let
8 cfg = config.hardware.acpilight;
9in
10{
11 options = {
12 hardware.acpilight = {
13 enable = lib.mkOption {
14 default = false;
15 type = lib.types.bool;
16 description = ''
17 Enable acpilight.
18 This will allow brightness control via xbacklight from users in the video group
19 '';
20 };
21 };
22 };
23
24 config = lib.mkIf cfg.enable {
25 environment.systemPackages = with pkgs; [ acpilight ];
26 services.udev.packages = with pkgs; [ acpilight ];
27 };
28}