summaryrefslogtreecommitdiff
path: root/ql/settings.py
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2016-11-25 22:26:19 +0100
committeremkael <emkael@tlen.pl>2016-11-25 22:26:19 +0100
commit6d5ae86eac297cbc62d56c0479582e50207b05bd (patch)
treed234ee1faad574ac3a1724f5d8a22fbf6ae897c5 /ql/settings.py
parent542e7cfbf6c543a234309feb42d087779a7cdc12 (diff)
More verbose config-related messages
Diffstat (limited to 'ql/settings.py')
-rwxr-xr-xql/settings.py12
1 files changed, 9 insertions, 3 deletions
diff --git a/ql/settings.py b/ql/settings.py
index df68ae3..7d8af00 100755
--- a/ql/settings.py
+++ b/ql/settings.py
@@ -1,4 +1,4 @@
-import json, sys
+import json, os, sys
def _fetch_settings(config_path, constant_config, default_config):
try:
@@ -8,10 +8,16 @@ def _fetch_settings(config_path, constant_config, default_config):
except FileNotFoundError:
with open(config_path, 'w') as new_config:
json.dump(default_config, new_config)
- print('Config file created, fill it up!')
+ print(
+ 'Config file %s created, fill it up!' %
+ os.path.realpath(config_path)
+ )
sys.exit()
except ValueError:
- print('Config file invalid, fix it!')
+ print(
+ 'Config file %s invalid, fix it!' %
+ os.path.realpath(config_path)
+ )
sys.exit(1)
DATABASES = {