-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathpyproject.toml
214 lines (191 loc) · 5.29 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
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
[tool.poetry]
name = "maya_umbrella"
version = "0.14.2"
description = "A better Autodesk Maya antivirus tool detects and removes malicious."
homepage = "https://github.com/loonghao/maya_umbrella"
repository = "https://github.com/loonghao/maya_umbrella"
documentation = "https://github.com/loonghao/maya_umbrella"
keywords = ["Autodesk Maya", "python", "Maya", "dcc", "antivirus", "Security Tools", "maya_umbrella"]
authors = ["longhao <[email protected]>"]
license = "MIT"
readme = "README.md"
classifiers = [
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
]
include = [
{ path = "maya_umbrella/locales", format = ["sdist", "wheel"] },
]
packages = [
{ include = "maya_umbrella" },
]
[tool.poetry.build]
generate-setup-file = false
[tool.poetry.dependencies]
python = ">=2.7,<2.8 || >=3.6.0"
[tool.poetry.dev-dependencies]
nox = { version = "^2024.3.2", python = ">=3.8.1,<3.11" }
[tool.commitizen]
name = "cz_conventional_commits"
version = "0.14.2"
tag_format = "v$version"
version_files = [
"pyproject.toml:version",
"maya_umbrella/__version__.py"
]
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.black]
line-length = 120
target-version = ['py36', 'py37', 'py38', 'py39']
include = '\.pyi?$'
exclude = '''
(
/(
\.eggs # exclude a few common directories in the
| \.git # root of the project
| \.hg
| \.mypy_cache
| \.tox
| \.nox
| \.venv
| _build
| buck-out
| build
| maya_umbrella/_vendor
| dist
)/
| foo.py # also separately exclude a file named foo.py in
# the root of the project
)
'''
[tool.isort]
profile = "black"
atomic = true
include_trailing_comma = true
lines_after_imports = 2
lines_between_types = 1
use_parentheses = true
src_paths = ["maya_umbrella", "tests"]
filter_files = true
known_first_party = "maya_umbrella"
# Enforce import section headers.
import_heading_future = "Import future modules"
import_heading_stdlib = "Import built-in modules"
import_heading_thirdparty = "Import third-party modules"
import_heading_firstparty = "Import local modules"
force_sort_within_sections = true
force_single_line = true
# All project unrelated unknown imports belong to third-party.
default_section = "THIRDPARTY"
skip_glob = ["*/docs/conf.py", "*/maya_umbrella/_vendor/*"]
# https://beta.ruff.rs/docs/configuration/
[tool.ruff]
exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".ipynb_checkpoints",
".mypy_cache",
".nox",
".pants.d",
".pyenv",
".pytest_cache",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
".vscode",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"site-packages",
"venv",
"dev",
"maya_umbrella/_vendor/",
"noxfile.py",
]
line-length = 120
[tool.ruff.lint]
fixable = ["ALL"]
extend-select = [
"Q",
"RUF100",
"C90",
"UP",
"I",
"D",
"DTZ005", # https://docs.astral.sh/ruff/rules/call-datetime-now-without-tzinfo/
] # add "T" to disallow prints
flake8-quotes = { inline-quotes = "double", multiline-quotes = "double" }
ignore = [
"I001",
"D107", # ignore missing docstring in __init__ methods
"D100", # ignore missing docstring in module
"D101",
"D102",
"D103", # ignore missing docstring in public class
"D104", # ignore missing docstring in public package
"D105", # ignore missing docstring in magic methods
"C901", # ignore too complex functions, doesn't seem to be worth it
"UP032",
"UP004",
"UP025",
]
[tool.ruff.lint.mccabe]
max-complexity = 45
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.per-file-ignores]
"tests/**/*.py" = ["D"]
"docs/*.py" = ["D"]
"dev/*.py" = ["D"]
[tool.ruff.format]
docstring-code-format = true
quote-style = "double"
######################################################################################
# vendoring
[tool.vendoring]
destination = "maya_umbrella/_vendor/"
requirements = "maya_umbrella/_vendor/vendor.txt"
namespace = "maya_umbrella._vendor"
protected-files = ["__init__.py", "README.rst", "vendor.txt"]
[tool.vendoring.transformations]
drop = [
# contains unnecessary scripts
"bin/",
# interpreter and OS specific msgpack libs
"msgpack/*.so",
# unneeded parts of setuptools
"easy_install.py",
"setuptools",
"pkg_resources/_vendor/",
"_distutils_hack",
"distutils-precedence.pth",
"pkg_resources/extern/",
# trim vendored pygments styles and lexers
"pygments/styles/[!_]*.py",
'^pygments/lexers/(?!python|__init__|_mapping).*\.py$',
]
[tool.vendoring.typing-stubs]
six = ["six.__init__", "six.moves.__init__", "six.moves.configparser"]
distro = []
[tool.vendoring.license.directories]
setuptools = "pkg_resources"
[tool.vendoring.license.fallback-urls]
distlib = "https://bitbucket.org/pypa/distlib/raw/master/LICENSE.txt"
webencodings = "https://github.com/SimonSapin/python-webencodings/raw/master/LICENSE"