symlink share/isso.conf to isso/defaults.ini and include it properly

This commit is contained in:
Martin Zimmermann 2016-01-09 00:15:04 +01:00
parent 5eb101fcb3
commit 93e783ed60
4 changed files with 5 additions and 3 deletions

View File

@ -7,3 +7,5 @@ include isso/js/embed.min.js
include isso/js/embed.dev.js include isso/js/embed.dev.js
include isso/js/count.min.js include isso/js/count.min.js
include isso/js/count.dev.js include isso/js/count.dev.js
include isso/defaults.ini

View File

@ -223,7 +223,7 @@ def main():
serve = subparser.add_parser("run", help="run server") serve = subparser.add_parser("run", help="run server")
args = parser.parse_args() args = parser.parse_args()
conf = config.load(join(dist.location, "share", "isso.conf"), args.conf) conf = config.load(join(dist.location, dist.project_name, "defaults.ini"), args.conf)
if args.command == "import": if args.command == "import":
conf.set("guard", "enabled", "off") conf.set("guard", "enabled", "off")

View File

@ -22,7 +22,7 @@ class Dispatcher(DispatcherMiddleware):
a relative URI, e.g. /foo.example and /other.bar. a relative URI, e.g. /foo.example and /other.bar.
""" """
default = os.path.join(dist.location, "share", "isso.conf") default = os.path.join(dist.location, dist.project_name, "defaults.ini")
def __init__(self, *confs): def __init__(self, *confs):

View File

@ -9,6 +9,6 @@ from isso import dist, config
application = make_app( application = make_app(
config.load( config.load(
os.path.join(dist.location, "share", "isso.conf"), os.path.join(dist.location, dist.project_name, "defaults.ini"),
os.environ.get('ISSO_SETTINGS')), os.environ.get('ISSO_SETTINGS')),
multiprocessing=True) multiprocessing=True)