From 91a993a8f7ea7976c584cf3c753c807a599f4229 Mon Sep 17 00:00:00 2001 From: LavaDesu Date: Sat, 15 Mar 2025 22:36:14 +1100 Subject: [PATCH] user/eww-wayland: fix title script to truncate properly --- res/eww-wayland/scripts/title.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/res/eww-wayland/scripts/title.sh b/res/eww-wayland/scripts/title.sh index fd7b798..108e0a5 100755 --- a/res/eww-wayland/scripts/title.sh +++ b/res/eww-wayland/scripts/title.sh @@ -9,9 +9,10 @@ out () { } init=$(hyprctl activewindow -j | jq --raw-output .title) -out "$init" +trunc=$(echo $init | cut -c-60) +out "$trunc" socat -u UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - | stdbuf -o0 awk -F '>>|,' '/^activewindow>>/{print $3}' | while read -r line ; do - trunc=$(echo $line | cut -c-85) + trunc=$(echo $line | cut -c-60) out "$trunc" done