forked from OpenEPaperLink/Home_Assistant_Integration
-
Notifications
You must be signed in to change notification settings - Fork 0
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 OpenEPaperLink#114 from rohankapoorcom/use-relativ…
…e-paths Remove hardcoded paths to config and use relative paths
- Loading branch information
Showing
4 changed files
with
27 additions
and
9 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
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,13 +1,21 @@ | ||
{ | ||
"domain": "open_epaper_link", | ||
"name": "OpenEPaperLink", | ||
"codeowners": ["@jonasniesner"], | ||
"codeowners": [ | ||
"@jonasniesner" | ||
], | ||
"config_flow": true, | ||
"dependencies": ["recorder"], | ||
"dependencies": [ | ||
"recorder" | ||
], | ||
"documentation": "https://github.com/jonasniesner/open_epaper_link_homeassistant", | ||
"integration_type": "hub", | ||
"iot_class": "local_push", | ||
"issue_tracker": "https://github.com/jonasniesner/open_epaper_link_homeassistant/issues", | ||
"requirements": ["qrcode[pil]"], | ||
"requirements": [ | ||
"qrcode[pil]==7.4.2", | ||
"requests_toolbelt==1.0.0", | ||
"websocket-client==1.7.0" | ||
], | ||
"version": "0.1.4" | ||
} | ||
} |
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,8 @@ | ||
|
||
def get_image_folder(hass): | ||
"""Return the folder where images are stored.""" | ||
return hass.config.path("www/open_epaper_link") | ||
|
||
def get_image_path(hass, entity_id): | ||
"""Return the path to the image for a specific tag.""" | ||
return hass.config.path("www/open_epaper_link/open_epaper_link."+ str(entity_id).lower() + ".jpg") |