Use nc instead of socat because socat is dying inexplicably
Some checks failed
/ check (push) Failing after 2m6s

This commit is contained in:
Daniel Flanagan 2025-01-22 09:25:09 -06:00
parent bc197b4cfd
commit 7df555a756

View file

@ -57,14 +57,16 @@ workspaces() {
)" )"
} }
workspace_reader() {
while read -r l; do
workspaces "$l"
done
}
# initial render # initial render
workspaces workspaces
# listen to events and re-render # listen to events and re-render
while true; do nc -U "$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock" | workspace_reader
# TODO: not sure why this socat | read invocation seems to stop?
socat - "UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock" | while read -r line; do echo '(box "EXITING")'
workspaces "$line"
done
done
echo '(box "DONE")'