Skip to content

Commit 60432a9

Browse files
committed
Switch to ruff's formatter and import sorting
1 parent 595bd1d commit 60432a9

2 files changed

Lines changed: 4 additions & 13 deletions

File tree

.github/workflows/ci.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,6 @@ jobs:
7272
- name: Check formatting
7373
if: always()
7474
run: |
75-
hatch run style:format
7675
git diff --color --exit-code
7776
- name: Check types
7877
if: always()

pyproject.toml

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -87,17 +87,14 @@ check = [
8787
skip-install = true
8888
dependencies = [
8989
"ruff",
90-
"isort",
91-
"black",
9290
]
9391
[tool.hatch.envs.style.scripts]
9492
fix = [
9593
"ruff check --fix mkdocs_section_index tests",
9694
"format",
9795
]
9896
format = [
99-
"isort -q mkdocs_section_index tests",
100-
"black -q mkdocs_section_index tests",
97+
"ruff format -q mkdocs_section_index tests",
10198
]
10299

103100
[tool.hatch.envs.docs]
@@ -107,15 +104,10 @@ dependencies = [
107104
"mkdocs-material >=7.3.6",
108105
]
109106

110-
[tool.black]
111-
line-length = 100
112-
113-
[tool.isort]
114-
profile = "black"
115-
line_length = 100
116-
117107
[tool.ruff]
108+
line-length = 100
118109
select = [
110+
"I",
119111
"F", "W", "E", "UP", "YTT", "C4", "DTZ", "FA", "ISC", "PIE", "T20", "RSE", "TCH",
120112
"B002", "B003", "B005", "B007", "B009", "B012", "B013", "B014", "B015", "B018", "B020", "B021", "B023", "B026", "B033", "B034", "B905",
121113
"COM818",
@@ -132,7 +124,7 @@ allow-dict-calls-with-keyword-arguments = true
132124

133125
[tool.mypy]
134126
warn_unreachable = true
135-
show_error_codes = true
127+
allow_redefinition = true
136128

137129
[tool.pytest.ini_options]
138130
addopts = "--tb=native"

0 commit comments

Comments
 (0)