Use nc instead of socat because socat is dying inexplicably
Some checks failed
/ check (push) Failing after 2m6s
Some checks failed
/ check (push) Failing after 2m6s
This commit is contained in:
parent
bc197b4cfd
commit
7df555a756
1 changed files with 9 additions and 7 deletions
|
@ -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")'
|
|
||||||
|
|
Loading…
Reference in a new issue