From 59be6da865903f1fa22894b22069508323b29c33 Mon Sep 17 00:00:00 2001 From: Calum Andrew Morrell Date: Sun, 9 Nov 2025 15:17:01 +0000 Subject: [PATCH] Prepared project for markdownx & tagulous. --- config/settings.py | 28 ++++++++++++++++++++++++++++ config/urls.py | 1 + 2 files changed, 29 insertions(+) diff --git a/config/settings.py b/config/settings.py index 68ca2c4..282c6c1 100644 --- a/config/settings.py +++ b/config/settings.py @@ -45,6 +45,7 @@ INSTALLED_APPS = [ "django.contrib.staticfiles", "core", "dashboard", + "markdownx", ] MIDDLEWARE = [ @@ -128,6 +129,8 @@ USE_TZ = True STATIC_URL = "static/" STATIC_ROOT = BASE_DIR / "static" +MEDIA_URL = "media" +MEDIA_ROOT = BASE_DIR / "media" # User model and authentication @@ -136,6 +139,31 @@ LOGIN_REDIRECT_URL = "dashboard:dashboard" LOGOUT_REDIRECT_URL = "core:homepage" +# Email backend configuration +# DEFAULT_FROM_EMAIL = 'system@dazed-gerbil.com' +# EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend' +# EMAIL_HOST = os.getenv('EMAIL_HOST') +# EMAIL_PORT = os.getenv('EMAIL_PORT') +# EMAIL_USE_TLS = (os.getenv('EMAIL_USE_TLS') == 'True') +# EMAIL_HOST_USER = os.getenv('EMAIL_HOST_USER') +# EMAIL_HOST_PASSWORD = os.getenv('EMAIL_HOST_PASSWORD') + + +# Tagulous config +SERIALIZATION_MODULES = { + "xml": "tagulous.serializers.xml_serializer", + "json": "tagulous.serializers.json", + "python": "tagulous.serializers.python", + "yaml": "tagulous.serializers.pyyaml", +} + + +# Markdownx config +MARKDOWNX_MARKDOWN_EXTENSIONS = [ + "markdown.extensions.extra", +] + + # Default primary key field type # https://docs.djangoproject.com/en/5.2/ref/settings/#default-auto-field diff --git a/config/urls.py b/config/urls.py index 222ea61..5f021b6 100644 --- a/config/urls.py +++ b/config/urls.py @@ -23,4 +23,5 @@ urlpatterns = [ path("", include("core.urls", namespace="core")), path("accounts/", include("accounts.urls")), path("dashboard/", include("dashboard.urls", namespace="dashboard")), + path("markdownx/", include("markdownx.urls")), ]