From 607d8fad96436b134424b9935166a7cd0884003e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Na=C3=AFm=20Favier?= Date: Sun, 4 Jun 2023 15:23:23 +0200 Subject: [PATCH] i3-sway: quote output names (#4059) They can contain spaces. --- .../services/window-managers/i3-sway/lib/functions.nix | 2 +- .../window-managers/i3/i3-workspace-output-expected.conf | 8 ++++---- .../sway/sway-workspace-output-expected.conf | 8 ++++---- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/modules/services/window-managers/i3-sway/lib/functions.nix b/modules/services/window-managers/i3-sway/lib/functions.nix index d8f51e785..38966faf1 100644 --- a/modules/services/window-managers/i3-sway/lib/functions.nix +++ b/modules/services/window-managers/i3-sway/lib/functions.nix @@ -150,7 +150,7 @@ rec { windowCommandsStr = { command, criteria, ... }: "for_window ${criteriaStr criteria} ${command}"; workspaceOutputStr = item: - ''workspace "${item.workspace}" output ${item.output}''; + ''workspace "${item.workspace}" output "${item.output}"''; indent = list: { includesWrapper ? true, level ? 1 }: diff --git a/tests/modules/services/window-managers/i3/i3-workspace-output-expected.conf b/tests/modules/services/window-managers/i3/i3-workspace-output-expected.conf index 9aca04fca..c4d36b656 100644 --- a/tests/modules/services/window-managers/i3/i3-workspace-output-expected.conf +++ b/tests/modules/services/window-managers/i3/i3-workspace-output-expected.conf @@ -94,7 +94,7 @@ bar { } } -workspace "1" output eDP -workspace "ABC" output DP -workspace "3: Test" output HDMI -workspace "!"§$%&/(){}[]=?\*#<>-_.:,;²³" output DVI +workspace "1" output "eDP" +workspace "ABC" output "DP" +workspace "3: Test" output "HDMI" +workspace "!"§$%&/(){}[]=?\*#<>-_.:,;²³" output "DVI" diff --git a/tests/modules/services/window-managers/sway/sway-workspace-output-expected.conf b/tests/modules/services/window-managers/sway/sway-workspace-output-expected.conf index 3fd76e0ef..2e02cec60 100644 --- a/tests/modules/services/window-managers/sway/sway-workspace-output-expected.conf +++ b/tests/modules/services/window-managers/sway/sway-workspace-output-expected.conf @@ -103,8 +103,8 @@ bar { } } -workspace "1" output eDP -workspace "ABC" output DP -workspace "3: Test" output HDMI -workspace "!"§$%&/(){}[]=?\*#<>-_.:,;²³" output DVI +workspace "1" output "eDP" +workspace "ABC" output "DP" +workspace "3: Test" output "HDMI" +workspace "!"§$%&/(){}[]=?\*#<>-_.:,;²³" output "DVI" exec "/nix/store/00000000000000000000000000000000-dbus/bin/dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK XDG_CURRENT_DESKTOP XDG_SESSION_TYPE NIXOS_OZONE_WL; systemctl --user start sway-session.target"