forked from real-yfprojects/sphinx-polyversion
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
139 lines (120 loc) · 3.8 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "sphinx_polyversion"
version = "0.5.0"
description = "Build multiple versions of your sphinx docs and merge them into one website."
readme = "README.md"
authors = ["yfprojects <[email protected]>"]
license = "MIT"
repository = "https://github.com/real-yfprojects/sphinx-polyversion"
keywords = ["utils", "documentation", "sphinx"]
classifiers = [
"Development Status :: 2 - Pre-Alpha",
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3.7",
"Intended Audience :: Developers",
"Typing :: Typed",
"Topic :: Documentation",
"Topic :: Documentation :: Sphinx",
"Topic :: Software Development :: Documentation",
"Topic :: Utilities",
]
[tool.poetry.dependencies]
virtualenv = { version = ">=20", optional = true }
python = ">=3.8"
jinja2 = { version = ">=3", optional = true }
[tool.poetry.extras]
virtualenv = ["virtualenv"]
jinja = ["jinja2"]
[tool.poetry.scripts]
sphinx-polyversion = "sphinx_polyversion.main:main"
[tool.poetry.group.lint.dependencies]
mypy = "^1.7.1"
ruff = "^0.1.6"
black = "^23.11.0"
[tool.poetry.group.test.dependencies]
pytest = "^7.4.3"
[tool.poetry.group.docs.dependencies]
sphinx = { version = "^7.2.6", python = ">=3.9" }
sphinx-argparse = "^0.3.2"
sphinx-rtd-theme-github-versions = "^1.1"
sphinx-rtd-theme = "^1.3.0"
myst-parser = "^2.0.0"
sphinx-notfound-page = "^1.0.0"
sphinx-copybutton = "^0.5.2"
furo = "^2023.9.10"
sphinxext-opengraph = "^0.8.2"
sphinx-autobuild = "^2021.3.14"
sphinx-design = "^0.5.0"
jinja2 = "^3.1.2"
[tool.black]
target-version = ['py38']
[tool.mypy]
files = "sphinx_polyversion/**.py"
python_version = "3.8"
strict = true
allow_redefinition = true
exclude = ["^(tests|docs)"]
[[tool.mypy.overrides]]
module = "virtualenv.*"
ignore_missing_imports = true
[tool.ruff]
target-version = "py38"
select = [
"T", # flake8-print
"I", # isort
"F", # pyflakes
"D", # pydocstyle
"E", # pycodestyle
"W",
"FLY", # flynt
"RUF", # ruff
"PL", # pylint
"TCH", # flake8-type-checking
"ASYNC", # flake8-async
"A", # flake8-builtins
"C", # flake8-comprehensions
"FA", # flake8-future-annotations
"ISC", # flake8-implicit-str-concat
"G", # flake8-implicit-str-concat
"INP", # flake8-no-pep420
"PT", # flake8-pytest-style
"RSE", # flake8-raise
"RET", # flake8-return
"SIM", # flake8-simplify
"PTH", # flake8-use-pathlib
"TD", # flake8-todos
"PYI", # flake8-pyi - lints .pyi type stubs
"ERA", # ERA
]
unfixable = ['ERA']
ignore = [
# pydocstyle
# "D202", # no-blank-line-after-function
"D203", # one-blank-line-before-class
# "D205", # blank-line-after-summary
"D212", # multi-line-summary-first-line
# "D401", # non-imperative-mood
# pycodestyle
"E501", # line-too-long
# pylint
"PLR0913", # too-many-arguments
# "PLR0912", # too-many-branches
# "PLR0915", # too-many-statements
# flake8-todos
"TD002", # missing author
]
# Same as Black.
line-length = 88
# Allow unused variables when underscore-prefixed or of form `dummyN`.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?)|dummy\\d*)$"
# Less strict rules for docs/*
[tool.ruff.per-file-ignores]
"docs/*" = ["PLR", "D1", "PTH", "INP"]
[tool.ruff.pylint]
# Allow more arguments for complexity check
max-args = 8
[tool.pytest.ini_options]
addopts = ["--import-mode=importlib"]