mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-11-06 10:16:44 +01:00
27 lines
457 B
Nix
27 lines
457 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
with lib;
|
|
|
|
let
|
|
cfg = config.programs.light;
|
|
|
|
in
|
|
{
|
|
options = {
|
|
programs.light = {
|
|
enable = mkOption {
|
|
default = false;
|
|
type = types.bool;
|
|
description = ''
|
|
Whether to install Light backlight control with setuid wrapper.
|
|
'';
|
|
};
|
|
};
|
|
};
|
|
|
|
config = mkIf cfg.enable {
|
|
environment.systemPackages = [ pkgs.light ];
|
|
security.setuidPrograms = [ "light" ];
|
|
};
|
|
}
|