From 41464de152a73acabc92f0bdb9f50c354607a523 Mon Sep 17 00:00:00 2001 From: Filippo Luca Ferretti <102977828+flferretti@users.noreply.github.com> Date: Fri, 5 Jul 2024 13:04:43 +0200 Subject: [PATCH 1/5] Delete .github/workflows/style.yml --- .github/workflows/style.yml | 66 ------------------------------------- 1 file changed, 66 deletions(-) delete mode 100644 .github/workflows/style.yml diff --git a/.github/workflows/style.yml b/.github/workflows/style.yml deleted file mode 100644 index c4a099df9..000000000 --- a/.github/workflows/style.yml +++ /dev/null @@ -1,66 +0,0 @@ -name: Code Style - -on: - push: - branches: [ "**" ] - tags-ignore: [ "**" ] - pull_request: - workflow_dispatch: - -jobs: - - black: - name: black - runs-on: ubuntu-latest - - steps: - - - name: "🔀 Checkout repository" - uses: actions/checkout@v4 - - - name: '🐍 Initialize Python' - uses: actions/setup-python@v5 - with: - python-version: "3.*" - - # Note: the black version needs to be in sync with what - # specified in setup.cfg. - - name: "📝 Black Code Formatter" - uses: psf/black@stable - with: - options: "--check --diff --color" - version: "~= 24.0" - - isort: - name: isort - runs-on: ubuntu-latest - - steps: - - - name: "🔀 Checkout repository" - uses: actions/checkout@v4 - - - name: '🐍 Initialize Python' - uses: actions/setup-python@v5 - with: - python-version: "3.*" - - # Workaround for https://github.com/isort/isort-action/issues/70 - - run: pip install colorama - - - name: "📝 isort" - uses: isort/isort-action@master - with: - configuration: "--check --diff --color" - - ruff: - name: ruff - runs-on: ubuntu-latest - - steps: - - - name: "🔀 Checkout repository" - uses: actions/checkout@v4 - - - name: "📝 Ruff" - uses: chartboost/ruff-action@v1 From 2033aa3ebeac9173aa6becfb7c16935c18415f9e Mon Sep 17 00:00:00 2001 From: Filippo Luca Ferretti Date: Fri, 5 Jul 2024 13:27:24 +0200 Subject: [PATCH 2/5] Add CI configuration --- .pre-commit-config.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2240dbd21..28643b49e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,3 +1,7 @@ +ci: + autofix_prs: false + autoupdate_schedule: quarterly + submodules: false repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.5.0 From ee14bd3811460a87971f97688bd242490473d23d Mon Sep 17 00:00:00 2001 From: Filippo Luca Ferretti Date: Fri, 5 Jul 2024 13:28:06 +0200 Subject: [PATCH 3/5] Add default language version and formatting options --- .pre-commit-config.yaml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 28643b49e..f12ce981f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -2,6 +2,10 @@ ci: autofix_prs: false autoupdate_schedule: quarterly submodules: false + +default_language_version: + python: python3.11 + repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.5.0 @@ -16,13 +20,13 @@ repos: rev: 24.2.0 hooks: - id: black - language_version: python3.11 + args: ["--check", "--diff"] - repo: https://github.com/pycqa/isort rev: 5.13.2 hooks: - id: isort - name: isort (python) + args: ["--check", "--diff"] - repo: https://github.com/astral-sh/ruff-pre-commit rev: v0.3.2 From c25a5770477749fdcb90dd764fe4e29f2391949b Mon Sep 17 00:00:00 2001 From: Filippo Luca Ferretti Date: Wed, 10 Jul 2024 12:11:28 +0200 Subject: [PATCH 4/5] Update Python version --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f12ce981f..19885ec3a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,7 +4,7 @@ ci: submodules: false default_language_version: - python: python3.11 + python: python3 repos: - repo: https://github.com/pre-commit/pre-commit-hooks From b79406c2f8805a8585039387d07e754e1333bafa Mon Sep 17 00:00:00 2001 From: Filippo Luca Ferretti Date: Mon, 8 Jul 2024 16:24:10 +0000 Subject: [PATCH 5/5] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/pre-commit-hooks: v4.5.0 → v4.6.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.5.0...v4.6.0) - [github.com/psf/black-pre-commit-mirror: 24.2.0 → 24.4.2](https://github.com/psf/black-pre-commit-mirror/compare/24.2.0...24.4.2) - [github.com/astral-sh/ruff-pre-commit: v0.3.2 → v0.5.1](https://github.com/astral-sh/ruff-pre-commit/compare/v0.3.2...v0.5.1) --- .pre-commit-config.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 19885ec3a..483464939 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -8,7 +8,7 @@ default_language_version: repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.5.0 + rev: v4.6.0 hooks: - id: check-ast - id: check-merge-conflict @@ -17,7 +17,7 @@ repos: - id: trailing-whitespace - repo: https://github.com/psf/black-pre-commit-mirror - rev: 24.2.0 + rev: 24.4.2 hooks: - id: black args: ["--check", "--diff"] @@ -29,7 +29,7 @@ repos: args: ["--check", "--diff"] - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.3.2 + rev: v0.5.1 hooks: - id: ruff