1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2025-01-11 03:29:50 +01:00

kanshi: use config.wayland.systemd.target

Also add `ConditionEnvironment`.
This commit is contained in:
Thiago Kenji Okada 2024-12-31 10:01:57 +00:00 committed by Robert Helgesson
parent 8587c2ff0e
commit d3c500a8f8
No known key found for this signature in database
GPG key ID: 96E745BD17AA17ED

View file

@ -286,7 +286,8 @@ in {
systemdTarget = mkOption { systemdTarget = mkOption {
type = types.str; type = types.str;
default = "sway-session.target"; default = config.wayland.systemd.target;
defaultText = literalExpression "config.wayland.systemd.target";
description = '' description = ''
Systemd target to bind to. Systemd target to bind to.
''; '';
@ -342,6 +343,7 @@ in {
Unit = { Unit = {
Description = "Dynamic output configuration"; Description = "Dynamic output configuration";
Documentation = "man:kanshi(1)"; Documentation = "man:kanshi(1)";
ConditionEnvironment = "WAYLAND_DISPLAY";
PartOf = cfg.systemdTarget; PartOf = cfg.systemdTarget;
Requires = cfg.systemdTarget; Requires = cfg.systemdTarget;
After = cfg.systemdTarget; After = cfg.systemdTarget;