Skip to content

Commit

Permalink
MNT: blue/isort/flake8 → ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
DimitriPapadopoulos committed Dec 26, 2023
1 parent 1436a6e commit 36876f9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 17 deletions.
17 changes: 6 additions & 11 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,13 @@ repos:
- id: check-case-conflict
- id: check-merge-conflict
- id: check-vcs-permalinks
- repo: https://github.com/grantjenks/blue
rev: v0.9.1
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.1.9
hooks:
- id: blue
- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
- id: isort
- repo: https://github.com/pycqa/flake8
rev: 6.1.0
hooks:
- id: flake8
- id: ruff
args: [--fix, --show-fix, --exit-non-zero-on-fix]
exclude: "^(doc|nisext|tools)/"
- id: ruff-format
exclude: "^(doc|nisext|tools)/"
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.5.1
Expand Down
12 changes: 6 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,8 @@ __version__ = version = {version!r}
__version_tuple__ = version_tuple = {version_tuple!r}
'''

[tool.blue]
[tool.ruff]
line_length = 99
target-version = ["py38"]
force-exclude = """
(
_version.py
Expand All @@ -120,10 +119,11 @@ force-exclude = """
)
"""

[tool.isort]
profile = "black"
line_length = 99
extend_skip = ["_version.py", "externals"]
[tool.ruff.lint]
select = ["E4", "E7", "E9", "F", "I", "Q"]

[tool.ruff.format]
quote-style = single

[tool.mypy]
python_version = "3.11"
Expand Down

0 comments on commit 36876f9

Please sign in to comment.