diff options
Diffstat (limited to 'nixos/modules/hardware/brightnessctl.nix')
-rw-r--r-- | nixos/modules/hardware/brightnessctl.nix | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/nixos/modules/hardware/brightnessctl.nix b/nixos/modules/hardware/brightnessctl.nix new file mode 100644 index 0000000000000..341e4b791c237 --- /dev/null +++ b/nixos/modules/hardware/brightnessctl.nix @@ -0,0 +1,30 @@ +{ config, lib, pkgs, ... }: + +with lib; +let + cfg = config.hardware.brightnessctl; +in +{ + + options = { + + hardware.brightnessctl = { + + enable = mkOption { + default = false; + type = types.bool; + description = '' + Enable brightnessctl in userspace. + This will allow brightness control from users in the video group. + ''; + + }; + }; + }; + + + config = mkIf cfg.enable { + services.udev.packages = with pkgs; [ brightnessctl ]; + }; + +} |