You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm working with a lot of eww variables set from eww update command only. It would be nice to have a way to know from a different process when eww reloads so i can reset the variables to their desired state again. A simple ipc signal perhaps? Or is there already something like that?
Proposed configuration syntax
No response
Additional context
No response
The text was updated successfully, but these errors were encountered:
1. Follow the eww log file and watch for the reload message
2. Use a deflisten variable to run a script that notifies your process
When eww reloads, deflisten variables are refreshed by restarting their associated scripts. You could write a script that sends a signal to some process.
Example:
;; test
(deflisten test
:initial ""
;; Replace this command with something that sends a signal to your process
"notify-send -e -t 1000 'Test' 'This is a test.'"
)
;; If you test this you will notice that the notify script only gets run once the window is opened.
;; That is why we need some window to reference our deflisten variable.
(defwindow test
:monitor 0
:geometry (geometry
:x "40%"
:y "40%"
:width "20%"
:height "20%"
:anchor "top left"
)
:stacking "fg"
:exclusive false
:focusable true
:namespace "eww-test-window"
;; An invisible label is one way to reference the variable.
;; I have not tested if this affects the layout.
(label :visible false :text "${test}")
)
As you can see this is a bit fragile. If you really needs this to be an external process that doesn't get started by eww, then I'd favor the first approach (watching the eww logs). Otherwise consider starting your process via eww deflisten variable directly, and skip the whole signalling business. Eww will restart your process when it reloads.
Description of the requested feature
I'm working with a lot of eww variables set from
eww update
command only. It would be nice to have a way to know from a different process when eww reloads so i can reset the variables to their desired state again. A simple ipc signal perhaps? Or is there already something like that?Proposed configuration syntax
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: