From 5ec296d319736fdb42dba9a46baa978ec86c5d75 Mon Sep 17 00:00:00 2001 From: emkael Date: Mon, 9 May 2016 23:41:43 +0200 Subject: * python config contained within python directory (symlinked) --- app/python/config | 1 + app/python/db.json | 1 - app/python/import_cals.py | 2 +- app/python/rcal/db.py | 2 +- 4 files changed, 3 insertions(+), 3 deletions(-) create mode 120000 app/python/config delete mode 120000 app/python/db.json diff --git a/app/python/config b/app/python/config new file mode 120000 index 0000000..899f698 --- /dev/null +++ b/app/python/config @@ -0,0 +1 @@ +../../config \ No newline at end of file diff --git a/app/python/db.json b/app/python/db.json deleted file mode 120000 index f6ad526..0000000 --- a/app/python/db.json +++ /dev/null @@ -1 +0,0 @@ -../../config/db.json \ No newline at end of file diff --git a/app/python/import_cals.py b/app/python/import_cals.py index f9e7fbd..ae33c84 100644 --- a/app/python/import_cals.py +++ b/app/python/import_cals.py @@ -17,7 +17,7 @@ BASEPATH = os.path.join( CONFIG = json.load(open( os.path.join( - BASEPATH, + os.environ['PYTHONPATH'], 'config', 'reddit-import.json'), 'r')) diff --git a/app/python/rcal/db.py b/app/python/rcal/db.py index 63561d7..7e892a1 100644 --- a/app/python/rcal/db.py +++ b/app/python/rcal/db.py @@ -13,7 +13,7 @@ class Session(object): def __init__(self): config = json.load( open(path.join(path.dirname( - path.realpath(__file__)), '..', 'db.json'))) + path.realpath(__file__)), '..', 'config', 'db.json'))) db_str = url.URL( drivername=config['type'], host=config['host'], -- cgit v1.2.3