Use ruff
This commit is contained in:
@@ -26,8 +26,7 @@ repos:
|
||||
hooks:
|
||||
- id: black
|
||||
|
||||
- repo: https://github.com/PyCQA/flake8
|
||||
rev: 6.0.0
|
||||
- repo: https://github.com/charliermarsh/ruff-pre-commit
|
||||
rev: 'v0.0.246'
|
||||
hooks:
|
||||
- id: flake8
|
||||
types: [file, python]
|
||||
- id: ruff
|
||||
|
||||
@@ -66,13 +66,13 @@ write_to = "src/sigal/version.py"
|
||||
line-length = 88
|
||||
target-version = ['py38']
|
||||
|
||||
[tool.flake8]
|
||||
max-line-length = "88"
|
||||
ignore = "E203,W503,E731"
|
||||
|
||||
[tool.distutils.isort]
|
||||
[tool.isort]
|
||||
profile = "black"
|
||||
|
||||
[tool.ruff]
|
||||
select = ["E", "F"]
|
||||
ignore = ["E731"]
|
||||
|
||||
[tool.coverage.run]
|
||||
source = ["sigal"]
|
||||
omit = [
|
||||
|
||||
@@ -80,7 +80,7 @@ class BaseCompressor:
|
||||
Otherwise, it returns False.
|
||||
|
||||
"""
|
||||
if not os.path.splitext(filename)[1][1:] in self.suffixes_to_compress:
|
||||
if os.path.splitext(filename)[1][1:] not in self.suffixes_to_compress:
|
||||
return False
|
||||
|
||||
file_stats = None
|
||||
|
||||
Reference in New Issue
Block a user