Skip to content

Commit cc84559

Browse files
committed
Move ruff config to its own file
1 parent cecf393 commit cc84559

File tree

2 files changed

+30
-7
lines changed

2 files changed

+30
-7
lines changed

pyproject.toml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,3 @@ build-backend = "setuptools.build_meta"
44

55
[tool.pytest.ini_options]
66
addopts = " --ignore django_prometheus/tests/end2end"
7-
8-
[tool.ruff]
9-
line-length = 120
10-
target-version = "py39"
11-
12-
[tool.ruff.lint]
13-
select = ["B", "C4", "E", "F", "I", "T10", "YTT", "W"]

ruff.toml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
line-length = 120
2+
target-version = "py39"
3+
4+
[lint]
5+
select = [
6+
# https://docs.astral.sh/ruff/rules/#flake8-bugbear-b
7+
# https://github.com/PyCQA/flake8-bugbear
8+
"B",
9+
# https://docs.astral.sh/ruff/rules/#flake8-comprehensions-c4
10+
# https://github.com/adamchainz/flake8-comprehensions
11+
"C4",
12+
# https://docs.astral.sh/ruff/rules/#error-e
13+
# https://github.com/PyCQA/pycodestyle
14+
"E",
15+
# https://docs.astral.sh/ruff/rules/#pyflakes-f
16+
# https://github.com/PyCQA/pyflakes
17+
"F",
18+
# https://docs.astral.sh/ruff/rules/#isort-i
19+
# https://pycqa.github.io/isort/
20+
"I",
21+
# https://docs.astral.sh/ruff/rules/#flake8-debugger-t10
22+
# https://github.com/jbkahn/flake8-debugger
23+
"T10",
24+
# https://docs.astral.sh/ruff/rules/#flake8-2020-ytt
25+
# https://github.com/asottile-archive/flake8-2020
26+
"YTT",
27+
# https://docs.astral.sh/ruff/rules/#warning-w
28+
# https://github.com/PyCQA/pycodestyle
29+
"W",
30+
]

0 commit comments

Comments
 (0)