Convert to ES5, add web server

* No compilation step
 * Beginnings of web interface
 * Simple express server; React-based frontend
 * CommonJS style across codebase; auto-converts to RequireJS for browser
 * Using diffsync for realtime UI
 * "Provider" -> "Plugin"
 * Plugins expose one or more Providers
This commit is contained in:
Nick Farina
2015-08-10 14:19:55 -07:00
parent bf5fc50fa6
commit dbedf7fe01
45 changed files with 52708 additions and 439 deletions

View File

@@ -21,21 +21,21 @@ You can run HomeBridge easily from the command line:
> homebridge server
```
It will look for any locally-installed providers and load them up automatically.
It will look for any locally-installed plugins and load them up automatically.
## Providers
## Plugins
HomeBridge does nothing by itself; in order to expose your home to HomeKit, you'll need to install one or more HomeBridge "Providers." A Provider is an npm module that connects with HomeBridge and registers accessories for devices in your home.
HomeBridge does nothing by itself; in order to expose your home to HomeKit, you'll need to install one or more HomeBridge "Plugins." A Plugin is an npm module that connects with HomeBridge and registers accessories for devices in your home.
Providers must be published to npm and tagged with `homebridge-provider`. The package name must contain the prefix `homebridge-`. For example, a valid package might be `homebridge-lockitron`.
Plugins must be published to npm and tagged with `homebridge-plugin`. The package name must contain the prefix `homebridge-`. For example, a valid package might be `homebridge-lockitron`.
Providers are automatically discovered and loaded from your home directory inside the `.homebridge` folder. For instance, the Lockitron provider would be placed here:
Plugins are automatically discovered and loaded from your home directory inside the `.homebridge` folder. For instance, the Lockitron plugin would be placed here:
```sh
~/.homebridge/providers/homebridge-lockitron
~/.homebridge/plugins/homebridge-lockitron
```
Right now you must copy providers manually (or symlink them from another location). The HomeBridge server will load and validate your Provider on startup. You can find an example Provider in [example-providers/homebridge-lockitron]().
Right now you must copy plugins manually (or symlink them from another location). The HomeBridge server will load and validate your Plugin on startup. You can find an example Plugin in [example-plugins/homebridge-lockitron]().
## Running from Source