Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AppDaemon separately #4

Open
mkinney opened this issue Jan 1, 2022 · 1 comment
Open

AppDaemon separately #4

mkinney opened this issue Jan 1, 2022 · 1 comment

Comments

@mkinney
Copy link
Collaborator

mkinney commented Jan 1, 2022

Not sure what AppDaemon is, but we can make the code handle it if you can describe what it does differently than from just running from main.

@joshpirihi
Copy link
Owner

It's an add-on for home assistant that is designed to let you run custom python automation scripts, but you don't have to interact with home assistant at all. It's a convenient place for me to run this script mainly.

Basically to run a script under AppDaemon, you need this:

import hassapi as hass

class OutsideLights(hass.Hass):

  def initialize(self):
  code code code

It must import the class then init it with the hass object. When running straight from CLI I had to bodge it to use main instead, and remove that hassapi import (which I don't have on my local machine)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants