diff --git a/modules/services/kanshi.nix b/modules/services/kanshi.nix index e54b83aa4..4e5e5f104 100644 --- a/modules/services/kanshi.nix +++ b/modules/services/kanshi.nix @@ -120,7 +120,7 @@ let '' profile ${name} { ${concatStringsSep "\n " (map outputStr outputs)} - '' + optionalString (exec != null) " ${exec}" + '' + '' + optionalString (exec != null) " exec ${exec}\n" + '' } ''; in { diff --git a/tests/modules/services/kanshi/basic-configuration.conf b/tests/modules/services/kanshi/basic-configuration.conf index 905a539d0..9d6442b98 100644 --- a/tests/modules/services/kanshi/basic-configuration.conf +++ b/tests/modules/services/kanshi/basic-configuration.conf @@ -2,6 +2,7 @@ profile desktop { output "eDP-1" disable output "Iiyama North America PLE2483H-DP" enable position 0,0 output "Iiyama North America PLE2483H-DP 1158765348486" enable mode 1920x1080 position 1920,0 scale 2.100000 transform flipped-270 + exec echo "1 two 3" } profile nomad { diff --git a/tests/modules/services/kanshi/basic-configuration.nix b/tests/modules/services/kanshi/basic-configuration.nix index 08a2c167e..15fbbb9ce 100644 --- a/tests/modules/services/kanshi/basic-configuration.nix +++ b/tests/modules/services/kanshi/basic-configuration.nix @@ -11,6 +11,7 @@ }]; }; desktop = { + exec = ''echo "1 two 3"''; outputs = [ { criteria = "eDP-1";