X-Git-Url: https://git.mdrn.pl/django-ssify.git/blobdiff_plain/3d5016c1dea235acae62c25606f7b65e1e75abd5..64c5163e7aead7eb60951e040998ade343c079c5:/ssify/conf.py diff --git a/ssify/conf.py b/ssify/conf.py new file mode 100644 index 0000000..c06eaa8 --- /dev/null +++ b/ssify/conf.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +# This file is part of django-ssify, licensed under GNU Affero GPLv3 or later. +# Copyright © Fundacja Nowoczesna Polska. See README.md for more information. +# +from django.conf import settings + + +class AppSettings(object): + prefix = 'SSIFY_' + + @classmethod + def add(cls, name, default): + setattr(cls, name, property(lambda self: + getattr(settings, self.prefix + name, default))) + + +AppSettings.add('CACHE_ALIASES', None) +AppSettings.add('RENDER', False) +AppSettings.add('RENDER_VERBOSE', False) + + +conf = AppSettings()