refactor: removing needless module complexity
This commit is contained in:
18
modules/nixos/programs/brightnessctl/default.nix
Normal file
18
modules/nixos/programs/brightnessctl/default.nix
Normal file
@@ -0,0 +1,18 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (lib) mkIf mkEnableOption;
|
||||
cfg = config.nixos.programs.brightnessctl;
|
||||
in {
|
||||
options = {
|
||||
nixos.programs.brightnessctl.enable = mkEnableOption "Enables brigthnessctl";
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
environment.systemPackages = [
|
||||
pkgs.brightnessctl
|
||||
];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user