Use ruff as linter and formatter (#2765)

* Switch from black to ruff format

* Sort dependencies with ruff check

* Run ruff format
This commit is contained in:
Matthew Hoffman authored and GitHub committed 2024-01-15 13:43:14 -08:00
1 parent 69ed6d4093
commit f0aadf9de8
83 files changed
+208 -429

No files matched your search

+6 -7
View File
@@ -12,16 +12,15 @@ repos:
files: '.*'
pass_filenames: false
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
rev: v4.5.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- repo: https://github.com/charliermarsh/ruff-pre-commit
# Ruff version.
rev: 'v0.0.267'
rev: v0.1.13
hooks:
- id: ruff
- repo: https://github.com/psf/black
rev: '23.3.0'
hooks:
- id: black
types_or: [ python, pyi, jupyter ]
args: [ --fix ]
- id: ruff-format
types_or: [ python, pyi, jupyter ]