sardemff7 / eventd

A simple daemon to track remote or local events and do actions the user wants to
https://www.eventd.org
Other
46 stars 4 forks source link

Add meta plugin support #11

Closed mathstuf closed 9 years ago

mathstuf commented 9 years ago

With bindings, plugins will need to go and find other plugins to work properly (eventd shouldn't know how to load a Ruby or Python plugin). Instead, a single Python plugin should have functions which go off and find Python modules which are plugins.

My idea is to have 3 symbols which are functions: one which returns a list of ids, another to get the context for an id and another for the get_interface function. The problem is that some state needs to be passed to the get_interface function (or some global state needs to be tracked ugh). Maybe better would be to pass a function which the meta plugin calls to register the plugins it finds back with the server? Unloading will also be interesting since the module can't be closed until all children plugins have been dealt with.

sardemff7 commented 9 years ago

I am currently experimenting around your GI work to provide script language plugins.

Once I will have the whole design settled, I will probably push something either to a branch in eventd or as a separated repository.

mathstuf commented 9 years ago

Alright, sounds good. Thanks.

sardemff7 commented 9 years ago

Got Ruby and Python working quite well. Ruby is not Exception-safe at all for now, so a plugin must define all the methods.

Code at eventd-bindings.

Closing this issue, please open one on eventd-bindings if needed. :-)