Initialize hasspy project with basic structure and MQTT client implementation
This commit is contained in:
commit
fa8bb1d8a9
9 changed files with 275 additions and 0 deletions
19
main.py
Normal file
19
main.py
Normal file
|
@ -0,0 +1,19 @@
|
|||
import tomllib
|
||||
|
||||
from hasspy.mqtt import HassClient
|
||||
|
||||
|
||||
def main() -> None:
|
||||
with open("config.toml", "rb") as file:
|
||||
config = tomllib.load(file)
|
||||
|
||||
ha = HassClient(
|
||||
"orchomenos",
|
||||
config=config,
|
||||
)
|
||||
|
||||
ha.loop_forever()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
Loading…
Add table
Add a link
Reference in a new issue