diff --git a/app/__init__.py b/app/__init__.py index 8970670..81f6729 100644 --- a/app/__init__.py +++ b/app/__init__.py @@ -4,13 +4,13 @@ import sys from flask import Flask # Please, set a config file on top project dir -# find example in ressources/app_config.py +# find example in ressources/pdc_config.py try: - from app_config import Config, ProdConfig, DevConfig, TestConfig + from pdc_config import Config, ProdConfig, DevConfig, TestConfig except ImportError: # TODO: use logging system - print("Please set an app_config.py file in you PYTHON_PATH") - print("(copy from resources/app_config.py)") + print("Please set an pdc_config.py file in you PYTHON_PATH") + print("See INSTALL.md for more info") sys.exit(-1) diff --git a/resources/app_config.py b/resources/app_config.py deleted file mode 100644 index 280e999..0000000 --- a/resources/app_config.py +++ /dev/null @@ -1,26 +0,0 @@ -import os - -root_dir = os.path.abspath(os.path.dirname(__file__)) - - -class Config(object): - with open(os.path.join(root_dir, 'VERSION.txt')) as version_file: - VERSION = version_file.read().strip() - - -class ProdConfig(Config): - TESTING = False - DEBUG = False - - -class DevConfig(Config): - DEBUG = True - - -class TestConfig(Config): - TESTING = True - DEBUG = True - # ignores @login_required decorator - # LOGIN_DISABLED = True - -# vim: tw=0 \ No newline at end of file diff --git a/resources/pdc_config.py b/resources/pdc_config.py new file mode 100644 index 0000000..280e999 --- /dev/null +++ b/resources/pdc_config.py @@ -0,0 +1,26 @@ +import os + +root_dir = os.path.abspath(os.path.dirname(__file__)) + + +class Config(object): + with open(os.path.join(root_dir, 'VERSION.txt')) as version_file: + VERSION = version_file.read().strip() + + +class ProdConfig(Config): + TESTING = False + DEBUG = False + + +class DevConfig(Config): + DEBUG = True + + +class TestConfig(Config): + TESTING = True + DEBUG = True + # ignores @login_required decorator + # LOGIN_DISABLED = True + +# vim: tw=0 \ No newline at end of file -- libgit2 0.21.2