## =====================================================================================
##  C O P Y R I G H T
## -------------------------------------------------------------------------------------
##  Copyright (c) 2023 by Robert Bosch GmbH. All rights reserved.
##
##  Author(s):
##  - Markus Braun, :em engineering methods AG (contracted by Robert Bosch GmbH)
## =====================================================================================

[tool.poetry]
name = "doxysphinx"
version = "3.3.12"
description = "Integrates doxygen html documentation with sphinx."
authors = [
    "Nirmal Sasidharan <nirmal.sasidharan@de.bosch.com>",
    "Markus Braun <markus.braun@em.ag>",
    "Aniket Salve <aniketdilip.salve@bosch.com>",
]
maintainers = ["Nirmal Sasidharan <nirmal.sasidharan@de.bosch.com>"]
license = "MIT"
homepage = "https://github.com/boschglobal/doxysphinx"
repository = "https://github.com/boschglobal/doxysphinx"
documentation = "https://boschglobal.github.io/doxysphinx/"
readme = "README.md"
keywords = ["DaC", "docs-as-code", "doxygen", "sphinx"]
classifiers = [
    "Framework :: Sphinx :: Extension",
    "Topic :: Software Development :: Build Tools",
    "Topic :: Software Development :: Documentation",
    "Topic :: Software Development :: Pre-processors",
    "Topic :: Text Processing :: Markup :: HTML",
    "Topic :: Text Processing :: Markup :: reStructuredText",
    "Topic :: Documentation :: Sphinx",
    "Topic :: Documentation",
]
packages = [{ include = "doxysphinx" }]

[tool.poetry.dependencies]
python = ">=3.9,<3.13"
lxml = ">=4.9.2,<=5.2.1"
colorama = { version = "^0.4.6", platform = "windows" }
click = "^8.1.3"
click-log = "^0.4.0"
pyparsing = "^3.0.9"
mpire = "^2.6.0"
pyjson5 = "^1.6.2"
libsass = "^0.22.0"
numpy = "^1.26.4"                                       # Adding this version of numpy to support python 3.12
matplotlib = "^3.8.4"

[tool.poetry.group.sphinx.dependencies]
sphinx = "<=7.3.7"
pillow = "^10.0.1"
sphinx-rtd-theme = "<=2.0.0"
sphinx-needs = "<=2.0.0"
sphinxcontrib-plantuml = "^0.26"
sphinxcontrib-doxylink = "^1.12.2"
sphinx-test-reports = "^1.0.2"
sphinx-theme = "^1.0"
sphinx-copybutton = "^0.5.2"
sphinx-book-theme = "^1.0.1"
myst-parser = ">=2.0.0,<=3.0.1"
toml = "^0.10.2"
sphinx-design = "^0.5.0"
sphinx-toolbox = "^3.5.0"
sphinx-autoapi = "^3.0.0"

[tool.poetry.group.typedefs.dependencies]
lxml-stubs = "^0.4.0"
types-pyyaml = "^6.0.12.2"

# ci build dependencies
[tool.poetry.group.ci]
optional = true
[tool.poetry.group.ci.dependencies]
pytest = "^7.2.2"
pytest-cov = "^4.0.0"
pytest-emoji = "^0.2.0"
pytest-md = "^0.2.0"
pex = "^2.1.131"
pre-commit = "^3.2.2"
commitizen = "^2.42.1"

[tool.poetry.scripts]
doxysphinx = "doxysphinx.cli:cli"

[tool.commitizen]
name = "cz_conventional_commits"
version = "3.3.12"
tag_format = "v$version"
version_files = ["pyproject.toml:^version"]
bump_message = """chore(release): release $current_version → $new_version by commitizen [skip-ci]

Signed-off-by: github-actions <actions@github.com>
"""

[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"

[tool.pytest.ini_options]
log_level = "DEBUG"
testpaths = ["tests"]
junit_logging = "out-err"
markers = ["speed: manual speed tests"]
addopts = "-m 'not speed'"

[tool.black]
line-length = 120
target-version = ['py38']
# black doesn't need further excludes because it honors the .gitignore file
extend-exclude = "(docs/)|(demo/)|(\\.vscode)|(\\.idea)|(\\.devcontainer)"

[tool.isort]
profile = "black"

[tool.bandit]
exclude_dirs = [
    ".git",
    ".build",
    ".devcontainer",
    ".github",
    ".idea",
    ".package",
    ".pytest_cache",
    "__pycache__",
    ".venv",
    ".vscode",
    "dist",
    "docs",
    "demo",
    "tests",
]

[tool.bandit.assert_used]
skips = ["*/test_*.py"]

[tool.mypy]
python_version = 3.8
show_error_codes = true
ignore_missing_imports = true

[tool.pydocstyle]
match_dir = "doxysphinx"
ignore = "D301,D213,D212,D203"

[tool.pylint]
disable = ["logging-fstring-interpolation"]
extension-pkg-allow-list = ["lxml", "mpire"]

[tool.pylint.FORMAT]
max-line-length = 120

[tool.pyright]
exclude = [
    ".build",
    ".cache",
    ".devcontainer",
    ".github",
    ".idea",
    ".mypy_cache",
    ".pytest_cache",
    ".venv",
    ".vscode",
    "demo",
    "dist",
    "docs",
    "external",
]
