bibliotek

package module
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 4, 2019 License: Apache-2.0 Imports: 0 Imported by: 0

README

🏛️ Bibliotek 📚 Build Status GitHub release hemtjanst godoc

Bibliotek ('library' in Swedish) provides common primitives and utilities for integrating with and extending the Hemtjänst platform.

Usage

client client godoc

The client package should be used if what you want to do is publish/control your own devices but do not care about other devices in the system.

For example, lets say you want to control devices connected to a Z-Wave network, or republish external datasources like an HTTP API as a device (e.g a temperature sensor).

server server godoc

The server package allows you to fetch all devices, their updates and send them commands. It does not allow for the creation of devices.

It can be used to implement things like a HomeKit bridge or to watch for and republish device data, like sensor readings, to another platform (e.g Prometheus).

Take a look at cmd/explorer on how to use it.

transport/mqtt client godoc

The transport/mqtt package contains everything needed to transport device data over MQTT. It also contains the Flags() and MustFlags() helpers that provide a set of flags to configure common MQTT options.

Contributing

Contributions are very welcome. Do ensure you run the tests:

$ go test -race -v -coverprofile=profile.cov $(go list ./...)
...

Note that in CI the _integration_test.go will run too. You can run them locally as well by setting BIBLIOTEK_TEST_INTEGRATION=1. These tests require Docker to run as they spin up an actual MQTT broker.

$ env BIBLIOTEK_TEST_INTEGRATION=1 go test -race -v -coverprofile=profile.cov $(go list ./...)
...

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
cmd
demo command
demo creates a bunch of fake devices defined in a config file in order to demo the hemtjänst system.
demo creates a bunch of fake devices defined in a config file in order to demo the hemtjänst system.
explorer command
transport

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL