[project]
name = "pelican"
authors = [
    { name = "Justin Mayer", email = "authors@getpelican.com" },
]
description = "Static site generator supporting Markdown and reStructuredText"
version = "4.11.0"
readme = "README.rst"
keywords = [
    "static site generator",
    "static sites",
    "ssg",
]
classifiers = [
    "Development Status :: 5 - Production/Stable",
    "Environment :: Console",
    "Framework :: Pelican",
    "Intended Audience :: End Users/Desktop",
    "License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)",
    "Operating System :: OS Independent",
    "Programming Language :: Python :: 3",
    "Programming Language :: Python :: 3.9",
    "Programming Language :: Python :: 3.10",
    "Programming Language :: Python :: 3.11",
    "Programming Language :: Python :: 3.12",
    "Programming Language :: Python :: 3.13",
    "Programming Language :: Python :: Implementation :: CPython",
    "Topic :: Internet :: WWW/HTTP :: Dynamic Content :: Content Management System",
    "Topic :: Internet :: WWW/HTTP :: Site Management",
    "Topic :: Software Development :: Libraries :: Python Modules",
    "Topic :: Text Processing :: Markup :: Markdown",
    "Topic :: Text Processing :: Markup :: HTML",
    "Topic :: Text Processing :: Markup :: reStructuredText",
]
requires-python = ">=3.9,<4.0"
dependencies = [
    "blinker>=1.7.0",
    "docutils>=0.20.1",
    "feedgenerator>=2.1.0",
    "jinja2>=3.1.2",
    "ordered-set>=4.1.0",
    "pygments>=2.16.1,<2.19.0",
    "python-dateutil>=2.8.2",
    "rich>=13.6.0",
    "unidecode>=1.3.7",
    "watchfiles>=0.21.0",
    "tzdata; sys_platform == 'win32'",
]

[project.license]
text = "AGPLv3"

[project.optional-dependencies]
markdown = [
    "markdown>=3.1",
]

[project.urls]
Homepage = "https://getpelican.com"
Funding = "https://donate.getpelican.com/"
"Issue Tracker" = "https://github.com/getpelican/pelican/issues"
Repository = "https://github.com/getpelican/pelican"
Documentation = "https://docs.getpelican.com"

[project.scripts]
pelican = "pelican.__main__:main"
pelican-import = "pelican.tools.pelican_import:main"
pelican-plugins = "pelican.plugins._utils:list_plugins"
pelican-quickstart = "pelican.tools.pelican_quickstart:main"
pelican-themes = "pelican.tools.pelican_themes:main"

[tool.autopub]
project-name = "Pelican"
git-username = "botpub"
git-email = "52496925+botpub@users.noreply.github.com"
changelog-file = "docs/changelog.rst"
changelog-header = "###############"
version-header = "="

[tool.pdm]
ignore_package_warnings = [
    "sphinx",
]

[tool.pdm.scripts]
docbuild = "invoke docbuild"
docserve = "invoke docserve"
lint = "invoke lint"
test = "invoke tests"

[tool.pdm.dev-dependencies]
dev = [
    "BeautifulSoup4>=4.12.2",
    "jinja2>=3.1.2",
    "lxml>=4.9.3",
    "markdown>=3.5.1",
    "typogrify>=2.1.0",
    "sphinx>=7.1.2",
    "sphinxext-opengraph>=0.9.0",
    "furo==2023.9.10",
    "livereload>=2.6.3",
    "psutil>=5.9.6",
    "pygments>=2.16.1,<2.19.0",
    "pytest>=7.4.3",
    "pytest-cov>=4.1.0",
    "pytest-sugar>=0.9.7",
    "pytest-xdist>=3.4.0",
    "tox>=4.11.3",
    "invoke>=2.2.0",
    "ruff==0.7.2",
    "tomli>=2.0.1; python_version < \"3.11\"",
]

[tool.pdm.build]
source-includes = [
    "CONTRIBUTING.rst",
    "THANKS",
    "docs/changelog.rst",
    "samples/",
]

[tool.ruff.lint]
select = [
    "E4",
    "E7",
    "E9",
    "F",
    "B",
    "C4",
    "EXE",
    "I",
    "ICN",
    "INP",
    "ISC",
    "PERF",
    "PIE",
    "PL",
    "PYI",
    "RSE",
    "RUF",
    "SLF",
    "SLOT",
    "TID",
    "UP",
    "Q",
    "TCH",
    "T10",
    "T20",
    "YTT",
]
ignore = [
    "PLW2901",
    "SLF001",
    "PLR0912",
    "PLR0913",
    "RUF005",
    "RUF012",
    "PLR0915",
    "INP001",
    "ISC001",
    "PERF203",
]

[tool.ruff.lint.extend-per-file-ignores]
"pelican/__init__.py" = [
    "E402",
]
"pelican/tests/test_utils.py" = [
    "RUF001",
]
"pelican/tests/test_generators.py" = [
    "PLR2004",
]
"pelican/tools/*.py}" = [
    "T201",
]

[build-system]
requires = [
    "pdm-backend",
]
build-backend = "pdm.backend"
