1
0
mirror of https://github.com/deadc0de6/dotdrop.git synced 2026-02-07 17:24:17 +00:00

dynamically find config file path for #108

This commit is contained in:
deadc0de6
2019-03-23 16:48:02 +01:00
parent 395ef0d1d2
commit 0495403ee3
2 changed files with 36 additions and 5 deletions

View File

@@ -87,6 +87,8 @@ class Cfg:
@profile: chosen profile
@debug: enable debug
"""
if not cfgpath:
raise ValueError('config file path undefined')
if not os.path.exists(cfgpath):
raise ValueError('config file does not exist: {}'.format(cfgpath))
# make sure to have an absolute path to config file