domsson / succade

Run, feed and style your Lemonbar with ease
Creative Commons Zero v1.0 Universal
55 stars 3 forks source link

What does a reload value of 0 do and is that intended? #8

Closed domsson closed 6 years ago

domsson commented 6 years ago

I need to go dig into my code to check what reload=0 would actually do. Then we can check if it makes sense to make this a value of special meaning, for example for static blocks that really only need to be executed once, then will show the same string for the rest of the bar's lifetime. That sounds useful to me.

domsson commented 6 years ago

So far, setting reload to 0 would lead to succade reloading that block all the time, which is a performance killer. As of 36ace83, setting reload = 0 will make the block static, meaning that it will only run once and then never again. If reload is set to a trigger command, reload will now be set to 0 internally, so that such blocks only run when their trigger has new input. Before, they would run on new input AND every 5 seconds, as that's the default reload value.