The current implementation requires add-ins to be present in the npm package and therefore in this repository. This is not perfect, as this limits the customizability tremendously. (Or you're forced to run homebridge in debug & plugin-dev mode, as I'm doing at the moment.)
So I would like to propose a small addition to the add-ins api:
1) add a new config option in knx_config named AddinsPath to define an absolute path to addins. (default /var/lib/homebridge/knx_addins/)
2) Check if a Handler-file exists in /lib/addins/, if not, check the AddinsPath for the file. (With something like fs.existsSync(path)
3) Load the handler like normal
Would you consider such a feature as sensible? I could start working on a PR. (should only be a few lines of code)
https://github.com/snowdd1/homebridge-knx/blob/2d5fdb7226c4894ff4e6f9f3ef5fbdeb99e8eb7d/lib/customServiceAPI.js#L21
The current implementation requires add-ins to be present in the npm package and therefore in this repository. This is not perfect, as this limits the customizability tremendously. (Or you're forced to run homebridge in debug & plugin-dev mode, as I'm doing at the moment.)
So I would like to propose a small addition to the add-ins api:
1) add a new config option in
knx_config
namedAddinsPath
to define an absolute path to addins. (default/var/lib/homebridge/knx_addins/
) 2) Check if a Handler-file exists in/lib/addins/
, if not, check theAddinsPath
for the file. (With something likefs.existsSync(path)
3) Load the handler like normalWould you consider such a feature as sensible? I could start working on a PR. (should only be a few lines of code)