mirror of
https://github.com/nix-community/home-manager.git
synced 2026-01-12 01:59:37 +08:00
hyprsunset: assert hyprland package is not null (#7518)
This commit is contained in:
@@ -72,7 +72,18 @@ in
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
systemd.user =
|
||||
assertions = [
|
||||
{
|
||||
assertion = (config.wayland.windowManager.hyprland.package != null);
|
||||
message = ''
|
||||
Can't set services.hyprsunset.enable if wayland.windowManager.hyprland.package
|
||||
is set to null. If you are using Hyprland's upstream flake, see:
|
||||
<https://github.com/nix-community/home-manager/issues/7484>.
|
||||
'';
|
||||
}
|
||||
];
|
||||
|
||||
systemd.user = lib.mkIf (config.wayland.windowManager.hyprland.package != null) (
|
||||
let
|
||||
# Create the main persistent service that maintains the IPC socket
|
||||
# Create a service for each transition in the transitions configuration
|
||||
@@ -139,6 +150,7 @@ in
|
||||
};
|
||||
}
|
||||
) cfg.transitions;
|
||||
};
|
||||
}
|
||||
);
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user