From ce07459e1e6cd636dd3c4bb26b7cadeec8de6001 Mon Sep 17 00:00:00 2001 From: Pierre Sassoulas Date: Tue, 14 Mar 2023 19:43:31 +0100 Subject: Upgrade pre-commit configuration and move to ruff (#2057) --- .pre-commit-config.yaml | 27 +++++---------------------- 1 file changed, 5 insertions(+), 22 deletions(-) (limited to '.pre-commit-config.yaml') diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 89c2cb88..c890717e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,17 +9,12 @@ repos: exclude: .github/|tests/testdata - id: end-of-file-fixer exclude: tests/testdata - - repo: https://github.com/PyCQA/autoflake - rev: v2.0.2 + - repo: https://github.com/charliermarsh/ruff-pre-commit + rev: "v0.0.255" hooks: - - id: autoflake - exclude: tests/testdata|astroid/__init__.py|astroid/scoped_nodes.py|astroid/node_classes.py - args: - - --in-place - - --remove-all-unused-imports - - --expand-star-imports - - --remove-duplicate-keys - - --remove-unused-variables + - id: ruff + exclude: tests/testdata + args: ["--fix"] - repo: https://github.com/Pierre-Sassoulas/copyright_notice_precommit rev: 0.1.2 hooks: @@ -33,11 +28,6 @@ repos: - id: pyupgrade exclude: tests/testdata args: [--py37-plus] - - repo: https://github.com/PyCQA/isort - rev: 5.12.0 - hooks: - - id: isort - exclude: tests/testdata - repo: https://github.com/Pierre-Sassoulas/black-disable-checker/ rev: v1.1.3 hooks: @@ -49,13 +39,6 @@ repos: - id: black args: [--safe, --quiet] exclude: tests/testdata - - repo: https://github.com/PyCQA/flake8 - rev: 6.0.0 - hooks: - - id: flake8 - additional_dependencies: - [flake8-bugbear==23.2.13, flake8-typing-imports==1.14.0] - exclude: tests/testdata|doc/conf.py - repo: local hooks: - id: pylint -- cgit v1.2.1