1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00

Added logic to main that prefers .yaml-config over .conf

This commit is contained in:
theolind
2015-02-28 17:42:23 +01:00
parent 223d2c2c3f
commit f2b602c7ec
2 changed files with 9 additions and 4 deletions

View File

@@ -112,6 +112,7 @@ def from_config_file(config_path, hass=None):
# Set config dir to directory holding config file
hass.config_dir = os.path.abspath(os.path.dirname(config_path))
config_dict = {}
# check config file type
if(os.path.splitext(config_path)[1] == '.yaml'):
# Read yaml