# -*- coding: utf-8 -*-
from pathlib import Path

from setuptools import find_namespace_packages, setup

install_requires: list = [
    "Django>=5,<6",
    "ocyan.core>=1.2.7",
    "ocyan.main>=2.0.1",
    "whitenoise",
    "uwsgidecorators-fallback",
]

extras_require: dict = {
    "test": [
        "wheel",
        "pylint-django",
        "isort",
        "ruff",
        "vdt.versionplugin.wheel",
        "coverage",
        "ocyan.plugin.testing",
        "oxyan.themes",
    ]
}

PACKAGE_CLASSIFIERS = [
    "Framework :: Ocyan",
    "Environment :: Plugins",
]

setup(
    name="ocyan.plugin.django",
    version="1.3.1",
    url="https://git.mandelblog.com/mandel-plugins/ocyan.plugin.django",
    author="Mandel",
    author_email="info@mandelblog.com",
    description="Installs Django and provides some essential configuration",
    long_description=Path("README.md").read_text(encoding="utf-8"),
    long_description_content_type="text/markdown",
    packages=find_namespace_packages(
        include=["ocyan", "ocyan.*", "empty_testproject", "empty_testproject.*"],
        exclude=[
            "ocyan.plugin.django.admin_extension",
            "ocyan.plugin.django.admin_extension.*",
            "ocyan.plugin.django.fixtures",
            "ocyan.plugin.django.fixtures.*",
            "ocyan.plugin.django.locale",
            "ocyan.plugin.django.locale.*",
        ],
    ),
    include_package_data=False,
    package_data={
        "ocyan.plugin.django": [
            "admin_extension/static/admin/css/*",
            "admin_extension/templates/admin/*",
            "fixtures/django/*",
            "locale/*/LC_MESSAGES/*",
        ]
    },
    python_requires=">=3.12,<3.13",
    install_requires=install_requires,
    extras_require=extras_require,
    classifiers=PACKAGE_CLASSIFIERS,
)
