summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2016-05-09 23:41:43 +0200
committeremkael <emkael@tlen.pl>2016-05-09 23:41:43 +0200
commit5ec296d319736fdb42dba9a46baa978ec86c5d75 (patch)
tree987002529991ff0c58e85e4d22b0886bfe3ea123
parentbc1e5d69f62c4a1d29ae6ac28a1d7dcb4b9f1a87 (diff)
* python config contained within python directory (symlinked)
l---------app/python/config1
l---------app/python/db.json1
-rw-r--r--app/python/import_cals.py2
-rw-r--r--app/python/rcal/db.py2
4 files changed, 3 insertions, 3 deletions
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'],