1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-12-05 16:41:04 +01:00

wallust: null package support

This commit is contained in:
Austin Horstman 2025-04-20 00:41:38 -05:00
parent aa2c7ac404
commit 6a676ee476

View file

@ -21,7 +21,9 @@ in
options.programs.wallust = {
enable = mkEnableOption "Wallust color scheme generator";
package = mkPackageOption pkgs "wallust" { };
package = mkPackageOption pkgs "wallust" { nullable = true; };
settings = mkOption {
type = tomlFormat.type;
default = { };
@ -38,7 +40,8 @@ in
};
};
config = mkIf cfg.enable {
home.packages = [ cfg.package ];
home.packages = lib.mkIf (cfg.package != null) [ cfg.package ];
xdg.configFile."wallust/wallust.toml" = mkIf (cfg.settings != { }) {
source = tomlFormat.generate "wallust.toml" cfg.settings;
};