1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-23 19:49:45 +01:00
home-manager/modules/services/redshift-gammastep/gammastep.nix
Thiago Kenji Okada 6b15b03898 redshift/gammastep: unify common options
Nowadays services.{redshift,gammastep} modules are really similar. They
should, since Gammastep is a fork of Redshift with the main objective is
to support Wayland.

So instead of trying to maintain two separate modules, this commit unify
the options in lib/options.nix file, making the implementation of the
module itself ends up being really simple (just calling the common
options with the necessary parameters to differentiate between them).
2021-01-26 01:39:50 -03:00

22 lines
568 B
Nix

{ config, lib, pkgs, ... }:
with lib;
let
commonOptions = import ./lib/options.nix {
inherit config lib;
moduleName = "gammastep";
programName = "Gammastep";
defaultPackage = pkgs.gammastep;
examplePackage = "pkgs.gammastep";
mainExecutable = "gammastep";
appletExecutable = "gammastep-indicator";
serviceDocumentation = "https://gitlab.com/chinstrap/gammastep/";
};
in {
meta = commonOptions.meta;
options.services.gammastep = commonOptions.options;
config = mkIf config.services.gammastep.enable commonOptions.config;
}