👷 Move to Ruff and add pre-commit (#661)

* 👷 Add pre-commit

* 🔧 Add pyproject.toml config for Ruff

*  Replace isort, flake8, autoflake with Ruff

* 🔨 Update lint and format scripts

* 🎨 Format with Ruff

* 🔧 Update Poetry config
This commit is contained in:
Sebastián Ramírez
2023-10-23 11:34:50 +04:00
committed by GitHub
parent 9ba3039106
commit 065fcdc828
6 changed files with 117 additions and 68 deletions

View File

@@ -1,6 +1,5 @@
#!/bin/sh -e
set -x
autoflake --remove-all-unused-imports --recursive --remove-unused-variables --in-place sqlmodel docs_src tests --exclude=__init__.py
black sqlmodel tests docs_src
isort sqlmodel tests docs_src
ruff sqlmodel tests docs_src scripts --fix
black sqlmodel tests docs_src scripts