fork/home-manager

git clone https://git.julia.blue/fork/home-manager

Robert HelgessonMerge PR #421575790441

master
801 B39 linesraw
1{ config, lib, pkgs, ... }:
2
3with lib;
4
5let
6
7  cfg = config.programs.eww;
8
9in {
10  meta.maintainers = [ hm.maintainers.mainrs ];
11
12  options.programs.eww = {
13    enable = mkEnableOption "eww";
14
15    package = mkOption {
16      type = types.package;
17      default = pkgs.eww;
18      defaultText = literalExpression "pkgs.eww";
19      example = literalExpression "pkgs.eww";
20      description = ''
21        The eww package to install.
22      '';
23    };
24
25    configDir = mkOption {
26      type = types.path;
27      example = literalExpression "./eww-config-dir";
28      description = ''
29        The directory that gets symlinked to
30        {file}`$XDG_CONFIG_HOME/eww`.
31      '';
32    };
33  };
34
35  config = mkIf cfg.enable {
36    home.packages = [ cfg.package ];
37    xdg.configFile."eww".source = cfg.configDir;
38  };
39}