domsson / succade

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

Reload blocks on signal #37

Open domsson opened 4 years ago

domsson commented 4 years ago

Other projects, like i3blocks and lemonblocks, offer the option to send a signal to request reloading of a certain block/module. It shouldn't be too hard to implement this in succade, so let's look into it.

In the config, blocks could then have a new option, signal, which could be assigned a signal number. When succade receives a user signal, it can check which block it matches and mark that block as "due". If the block is a live block, we should ignore the signal option with one exception: if the live block has died, we should restart it if there is a signal coming in.

domsson commented 3 years ago

Actually, this requires more changes to the code than I had originally anticipated, so I'm currently thinking to not implement this feature after all.