-
Notifications
You must be signed in to change notification settings - Fork 69
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #18 from LaggAt/feature/ble
Feature/ble
- Loading branch information
Showing
22 changed files
with
171 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,23 @@ | ||
// See https://aka.ms/vscode-remote/devcontainer.json for format details. | ||
{ | ||
"image": "ludeeus/container:integration-debian", | ||
// for development container on remote pi we need to clone source into the remote container, instead of bind: | ||
"workspaceFolder": "/workspaces/hacs-govee", | ||
"workspaceMount": "source=/usr/share/hassio/share/dev/hacs-govee,target=/workspaces/hacs-govee,type=bind,consistency=delegated", | ||
// "remoteEnv": { | ||
// "WS_PATH": "..", | ||
// }, | ||
// "containerEnv": { | ||
// "WS_PATH": "/usr/share/hassio/share/dev/hacs-govee", | ||
// }, | ||
"image": "ludeeus/container:python-base-debian", | ||
//"vsch.local.folder": "/usr/share/hassio/share/dev/hacs-govee", | ||
//"dockerFile": "Dockerfile", | ||
"name": "Govee integration development", | ||
"context": "..", | ||
"appPort": [ | ||
"9123:8123" | ||
], | ||
"postCreateCommand": "container install && python3 -m pip install --upgrade pip && pip3 install -r /workspaces/hacs-govee/requirements_test.txt", | ||
// "appPort": [ | ||
// "9123:8123" | ||
// ], | ||
"postCreateCommand": "/bin/echo ------------ postCreateCommand apt-get ------------ && apt-get update && apt-get -y install bash bluetooth bluez bluez-tools build-essential ca-certificates cython gcc git iputils-ping libatomic1 libavcodec-dev libc-dev libffi-dev libjpeg-dev libpcap-dev libssl-dev make nano openssh-client procps python3 python3-dev python3-dev python3-pip python3-setuptools rfkill unzip wget wget zlib1g-dev && /bin/echo ------------ postCreateCommand python/pip ------------ && /usr/local/bin/python3 -m pip install --upgrade pip && /usr/local/bin/pip3 install black colorlog debugpy pexpect pygatt pylint PyNaCl==1.3.0 && /usr/local/bin/pip3 install -r /workspaces/hacs-govee/requirements_test.txt && /bin/echo ------------ postCreateCommand container install ------------ && mkdir -p /src/ludeeus && cd /src/ludeeus && git clone https://github.com/ludeeus/container && cp -r ./container/rootfs/common/* / && chmod +x /usr/bin/container && /usr/bin/container install && /bin/echo ------------ postCreateCommand symlink our component ------------ && /bin/mkdir -p /config/custom_components && /bin/ln -s /workspaces/hacs-govee/custom_components/govee /config/custom_components/govee && /bin/echo ------------ postCreateCommand install hacs ------------ && mkdir -p /src/hacs && cd /src/hacs && /bin/mkdir -p /config/custom_components/hacs && /usr/bin/wget https://github.com/hacs/integration/releases/latest/download/hacs.zip && /usr/bin/unzip hacs.zip -d /config/custom_components/hacs && /bin/rm hacs.zip && /bin/echo ------------ postCreateCommand finished, starting HASS ------------ ", | ||
"extensions": [ | ||
"ms-python.python", | ||
"github.vscode-pull-request-github", | ||
|
@@ -29,6 +40,34 @@ | |
"editor.formatOnPaste": false, | ||
"editor.formatOnSave": true, | ||
"editor.formatOnType": true, | ||
"files.trimTrailingWhitespace": true | ||
} | ||
} | ||
"files.trimTrailingWhitespace": true, | ||
// to develop on your raspberry pi 4 (for BLE): | ||
"docker.host": "ssh://[email protected]", | ||
// also set docker.host for this workspace in vscode | ||
// create keys with "ssh-keygen -t rsa -b 4096" | ||
// also run this on your pi | ||
// copy your local id-rsa.pub content to /root/.ssh/authorized_keys | ||
// then configure remote-ssh to use key auth: "Remote-SSH: Open Configuration file": | ||
// Host 192.168.144.5 | ||
// HostName 192.168.144.5 | ||
// User root | ||
// ForwardAgent yes | ||
// IdentityFile C:\Users\root\.ssh\id_rsa | ||
// then in "Remote Containers: Re-build and re-open in container" | ||
}, | ||
"runArgs": [ | ||
"--name", | ||
"devcontainer_govee", | ||
"--network", | ||
"host", | ||
"--privileged", | ||
"-v", | ||
"/etc/machine-id:/etc/machine-id:ro", | ||
"-v", | ||
"/run/dbus:/run/dbus:ro", | ||
"-v", | ||
"/dev:/dev:ro", | ||
"-v", | ||
"/run/udev:/run/udev:ro", | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -136,3 +136,6 @@ dmypy.json | |
|
||
# Cython debug symbols | ||
cython_debug/ | ||
|
||
# other components in test environment | ||
custom_components/hacs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{ | ||
"python.linting.pylintEnabled": true, | ||
"python.linting.enabled": true, | ||
"python.pythonPath": "/usr/bin/python", | ||
"python.pythonPath": "/usr/local/bin/python", | ||
"files.associations": { | ||
"*.yaml": "home-assistant" | ||
}, | ||
|
@@ -11,5 +11,7 @@ | |
"python.testing.pytestEnabled": true, | ||
"python.testing.pytestArgs": [ | ||
"tests" | ||
] | ||
], | ||
"docker.host": "ssh://[email protected]", | ||
"docker.imageBuildContextPath": "/usr/share/hassio/share/dev/hacs-govee", | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
[[source]] | ||
url = "https://pypi.org/simple" | ||
verify_ssl = true | ||
name = "pypi" | ||
|
||
[packages] | ||
|
||
[dev-packages] | ||
|
||
[requires] | ||
python_version = "3.9" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
"""Govee LED strips platform.""" | ||
"""Govee platform.""" | ||
|
||
from datetime import timedelta | ||
import logging | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
{ | ||
"codeowners": ["@LaggAt"], | ||
"domain": "govee", | ||
"name": "Govee LED strips", | ||
"version": "0.1.6-beta.1", | ||
"name": "Govee", | ||
"version": "0.1.7", | ||
"config_flow": true, | ||
"documentation": "https://github.com/LaggAt/hacs-govee/blob/master/README.md", | ||
"issue_tracker": "https://github.com/LaggAt/hacs-govee/issues", | ||
"requirements": ["govee-api-laggat==0.1.37", "dacite==1.5.1"], | ||
"requirements": ["govee-api-laggat==0.1.38", "dacite==1.5.1"], | ||
"ssdp": [], | ||
"zeroconf": [], | ||
"homekit": {}, | ||
"dependencies": [], | ||
"codeowners": ["@LaggAt"] | ||
"dependencies": [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "govee", | ||
"hacs": "0.1.6-beta.1", | ||
"hacs": "0.1.7", | ||
"domains": [ | ||
"light" | ||
], | ||
|
Oops, something went wrong.