From 0c279c79e350e61b094dc10487c60faab93b221c Mon Sep 17 00:00:00 2001 From: Guilhem Saurel <guilhem.saurel@laas.fr> Date: Thu, 21 Mar 2024 20:17:09 +0100 Subject: [PATCH] =?UTF-8?q?tooling:=20black=20&=20isort=20=E2=86=92=20ruff?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .pre-commit-config.yaml | 15 ++++----------- pyproject.toml | 10 ++++++++-- 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1a04744e..874f3096 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,17 +1,14 @@ ci: autoupdate_branch: devel repos: -- repo: https://github.com/PyCQA/isort - rev: 5.12.0 - hooks: - - id: isort -- repo: https://github.com/charliermarsh/ruff-pre-commit - rev: v0.1.4 +- repo: https://github.com/astral-sh/ruff-pre-commit + rev: v0.3.3 hooks: - id: ruff args: - --fix - --exit-non-zero-on-fix + - id: ruff-format - repo: https://github.com/cheshirekow/cmake-format-precommit rev: v0.6.13 hooks: @@ -22,7 +19,7 @@ repos: - id: toml-sort-fix exclude: poetry.lock - repo: https://github.com/pre-commit/mirrors-clang-format - rev: v17.0.4 + rev: v18.1.1 hooks: - id: clang-format args: @@ -45,7 +42,3 @@ repos: - id: fix-byte-order-marker - id: mixed-line-ending - id: trailing-whitespace -- repo: https://github.com/psf/black - rev: 23.10.1 - hooks: - - id: black diff --git a/pyproject.toml b/pyproject.toml index 48631bc7..a5333a8b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -16,5 +16,11 @@ license = "BSD-2-Clause" name = "hpp-manipulation" version = "5.0.0" -[tool.isort] -profile = "black" +[tool.ruff] +extend-exclude = ["cmake"] + +[tool.ruff.lint] +extend-select = ["I", "NPY", "RUF", "UP", "W"] + +[tool.tomlsort] +all = true -- GitLab