summaryrefslogtreecommitdiff
path: root/home-manager/modules/aesthetics/targets/helix.nix
blob: dde557e391f9a3d77c9eafd281066c5de424495a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{ config, lib, ... }: let
  cfg = config.aesthetics.targets.helix;
  aes = config.aesthetics;
in {
  options.aesthetics.targets.helix = {
    enable = lib.mkOption {
      type = lib.types.bool;
      default = aes.enableAllTargets;
      description = "Whether to enable the aesthetics helix target.";
    };
    theme = lib.mkOption {
      type = lib.types.str;
      default = "default";
      description = "The name of the theme to use for helix.";
    };
  };
  config = lib.mkIf (cfg.enable && config.programs.helix.enable) {
    programs.helix.settings.theme = "custom-default";
    home.file."helix-theme" = {
      target = ".config/helix/themes/custom-default.toml";
      text = /*toml*/ ''
        inherits = "${cfg.theme}"
        "ui.background" = { }
        "ui.statusline" = { bg = "" }
      '';
    };
  };
}