Skip to content

Commit 7f886ab

Browse files
committed
Add autoflake, isort, and black config to pyproject.toml
1 parent ebe2b80 commit 7f886ab

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

pyproject.toml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,39 @@ requires = [
55
"setuptools",
66
]
77
build-backend = "setuptools.build_meta"
8+
9+
10+
# autoflake is used for autoformatting Python code
11+
#
12+
# ref: https://github.com/PyCQA/autoflake#readme
13+
#
14+
[tool.autoflake]
15+
ignore-init-module-imports = true
16+
remove-all-unused-imports = true
17+
remove-duplicate-keys = true
18+
#remove-unused-variables = true
19+
20+
21+
# isort is used for autoformatting Python code
22+
#
23+
# ref: https://pycqa.github.io/isort/
24+
#
25+
[tool.isort]
26+
profile = "black"
27+
28+
29+
# black is used for autoformatting Python code
30+
#
31+
# ref: https://black.readthedocs.io/en/stable/
32+
#
33+
[tool.black]
34+
skip-string-normalization = true
35+
# target-version should be all supported versions, see
36+
# https://github.com/psf/black/issues/751#issuecomment-473066811
37+
target_version = [
38+
"py37",
39+
"py38",
40+
"py39",
41+
"py310",
42+
"py311",
43+
]

0 commit comments

Comments
 (0)