diff --git a/__init__.py b/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/install.py b/install.py index 53257ac..b889a9d 100755 --- a/install.py +++ b/install.py @@ -1,10 +1,11 @@ -#!/usr/bin/python3 +#!/srv/pandora/bin/python3 import os from os.path import join, abspath, basename, dirname -# change this -name = 'placeholder' +import ox + + overwrite = ( #('home', 'indiancinema'), #('infoView', 'indiancinema'), @@ -13,6 +14,12 @@ overwrite = ( base = abspath(dirname(__file__)) os.chdir(base) +name = os.path.basename(base) +config = join(base, 'config.jsonc') +if os.path.exists(config): + with open('/srv/pandora/northeast/config.jsonc') as fd: + name = ox.jsonc.load(fd)['site']['id'] + for root, folders, files in os.walk(join(base, 'static')): for f in files: src = join(root, f)