From 3409ef74caea4dbddd2ba84473af07c81299f421 Mon Sep 17 00:00:00 2001 From: GeoJulien Date: Tue, 9 Jan 2024 16:15:43 +0100 Subject: [PATCH 1/2] tooling: bump dev dependencies and update git hooks --- .pre-commit-config.yaml | 10 ++++++++-- requirements/development.txt | 9 ++++----- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 3600f5f8..ec7a9bcb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -7,7 +7,6 @@ repos: - id: check-added-large-files args: ["--maxkb=500"] - id: check-case-conflict - - id: check-toml - id: check-xml - id: check-yaml - id: detect-private-key @@ -24,10 +23,17 @@ repos: - id: remove-tabs args: ["--whitespaces-count", "4"] + - repo: https://github.com/charliermarsh/ruff-pre-commit + rev: "v0.1.11" + hooks: + - id: ruff + args: ["--fix-only", "--target-version=py39"] + - repo: https://github.com/psf/black rev: 23.12.1 hooks: - id: black + args: ["--target-version=py39"] - repo: https://github.com/pycqa/isort rev: 5.13.2 @@ -36,7 +42,7 @@ repos: args: ["--profile", "black", "--filter-files"] - repo: https://github.com/pycqa/flake8 - rev: 6.1.0 + rev: 7.0.0 hooks: - id: flake8 files: ^qgis_resource_sharing/.*\.py$ diff --git a/requirements/development.txt b/requirements/development.txt index 81bfad44..80b94a6b 100644 --- a/requirements/development.txt +++ b/requirements/development.txt @@ -2,8 +2,7 @@ # ------------------------------------------- black -flake8>=3.8,<4.1 -flake8-builtins>=1.5,<2.1 -flake8-isort>=4.0,<5.1 -flake8-qgis>=1,<1.1 -pre-commit>=2.18,<2.22 +flake8-builtins>=1.5 +flake8-isort>=6 +flake8-qgis>=1,<2 +pre-commit>=3,<3.8 From f78db5c62ce5285f81095dcf123b0ce93d4a80e0 Mon Sep 17 00:00:00 2001 From: Julien Date: Tue, 9 Jan 2024 19:57:27 +0100 Subject: [PATCH 2/2] Update development.txt --- requirements/development.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/requirements/development.txt b/requirements/development.txt index 80b94a6b..06b7d10e 100644 --- a/requirements/development.txt +++ b/requirements/development.txt @@ -4,5 +4,5 @@ black flake8-builtins>=1.5 flake8-isort>=6 -flake8-qgis>=1,<2 -pre-commit>=3,<3.8 +flake8-qgis>=1 +pre-commit>=3,<4