From b0e3596b76e0614048b694fd8b16b9ec916d0fba Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 3 Jul 2023 18:34:50 +0000 Subject: [PATCH 01/13] Bump README.md version to 0.0.276 --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 0af6b22..7306703 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ # ruff-pre-commit [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) -[![image](https://img.shields.io/pypi/v/ruff/0.0.275.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/l/ruff/0.0.275.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.275.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/v/ruff/0.0.276.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/l/ruff/0.0.276.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.276.svg)](https://pypi.python.org/pypi/ruff) [![Actions status](https://github.com/astral-sh/ruff-pre-commit/workflows/main/badge.svg)](https://github.com/astral-sh/ruff-pre-commit/actions) A [pre-commit](https://pre-commit.com/) hook for [Ruff](https://github.com/charliermarsh/ruff). @@ -18,7 +18,7 @@ Add this to your `.pre-commit-config.yaml`: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.275 + rev: v0.0.276 hooks: - id: ruff ``` @@ -28,7 +28,7 @@ Or, to enable autofix: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.275 + rev: v0.0.276 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] From 95f113d6340ab4348ecc5d912cf6e6b3465bfb86 Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 4 Jul 2023 21:55:36 +0000 Subject: [PATCH 02/13] Mirror: 0.0.277 --- .version | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.version b/.version index 5038e3d..0d3cc30 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -0.0.276 +0.0.277 diff --git a/setup.py b/setup.py index 0cbdec8..8726c02 100644 --- a/setup.py +++ b/setup.py @@ -6,5 +6,5 @@ setup( name='pre_commit_placeholder_package', version='0.0.0', - install_requires=['ruff==0.0.276'], + install_requires=['ruff==0.0.277'], ) From a140cebced144267061c4c325743934e7970e2cd Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 4 Jul 2023 21:55:37 +0000 Subject: [PATCH 03/13] Bump README.md version to 0.0.277 --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 7306703..18ccd5a 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ # ruff-pre-commit [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) -[![image](https://img.shields.io/pypi/v/ruff/0.0.276.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/l/ruff/0.0.276.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.276.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/v/ruff/0.0.277.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/l/ruff/0.0.277.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.277.svg)](https://pypi.python.org/pypi/ruff) [![Actions status](https://github.com/astral-sh/ruff-pre-commit/workflows/main/badge.svg)](https://github.com/astral-sh/ruff-pre-commit/actions) A [pre-commit](https://pre-commit.com/) hook for [Ruff](https://github.com/charliermarsh/ruff). @@ -18,7 +18,7 @@ Add this to your `.pre-commit-config.yaml`: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.276 + rev: v0.0.277 hooks: - id: ruff ``` @@ -28,7 +28,7 @@ Or, to enable autofix: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.276 + rev: v0.0.277 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] From 89791c7aee767f647d3b64bd71f2ace752107b84 Mon Sep 17 00:00:00 2001 From: Ali Hamdan Date: Sun, 9 Jul 2023 21:37:19 +0200 Subject: [PATCH 04/13] Add `jupyter` and `toml` file types (#44) ## Summary Add `jupyter` to the file types that ruff pre-commit hook runs on ## Test Plan This is what pre-commit uses to identify ".ipynb" files. See https://github.com/pre-commit/identify/blob/dc75a76b7fd7093a7a1d4159d6741884343af694/identify/extensions.py#L100 Also black does this https://github.com/psf/black/blob/main/.pre-commit-hooks.yaml Fixes #43 --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 5b44ede..ea64ea2 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -27,7 +27,7 @@ jobs: git config user.name 'Github Actions' git config --global user.email '41898282+github-actions[bot]@users.noreply.github.com' - - run: pre-commit-mirror --language python --package-name ruff --entry 'ruff check --force-exclude' --id ruff --types-or python --types-or pyi --require-serial --description "Run 'ruff' for extremely fast Python linting" . + - run: pre-commit-mirror --language python --package-name ruff --entry 'ruff check --force-exclude' --id ruff --types-or python --types-or pyi --types-or jupyter --types-or toml --require-serial --description "Run 'ruff' for extremely fast Python linting" . - run: git push origin HEAD:refs/heads/main --tags From d87e2b0f73c652a038d10877ab24fdedb470e463 Mon Sep 17 00:00:00 2001 From: Ali Hamdan Date: Mon, 10 Jul 2023 21:03:43 +0200 Subject: [PATCH 05/13] Revert adding toml and jupyter (#45) See https://github.com/astral-sh/ruff-pre-commit/issues/44#issuecomment-1629510474 --- .github/workflows/main.yml | 2 +- README.md | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ea64ea2..5b44ede 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -27,7 +27,7 @@ jobs: git config user.name 'Github Actions' git config --global user.email '41898282+github-actions[bot]@users.noreply.github.com' - - run: pre-commit-mirror --language python --package-name ruff --entry 'ruff check --force-exclude' --id ruff --types-or python --types-or pyi --types-or jupyter --types-or toml --require-serial --description "Run 'ruff' for extremely fast Python linting" . + - run: pre-commit-mirror --language python --package-name ruff --entry 'ruff check --force-exclude' --id ruff --types-or python --types-or pyi --require-serial --description "Run 'ruff' for extremely fast Python linting" . - run: git push origin HEAD:refs/heads/main --tags diff --git a/README.md b/README.md index 18ccd5a..5979d98 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,17 @@ Or, to enable autofix: args: [--fix, --exit-non-zero-on-fix] ``` +To run the hook on Jupyter Notebooks too: + +```yaml +- repo: https://github.com/astral-sh/ruff-pre-commit + # Ruff version. + rev: v0.0.277 + hooks: + - id: ruff + types_or: [python, pyi, jupyter] +``` + Ruff's pre-commit hook should be placed after other formatting tools, such as Black and isort, _unless_ you enable autofix, in which case, Ruff's pre-commit hook should run _before_ Black, isort, and other formatting tools, as Ruff's autofix behavior can output code changes that require From bbb75905dc5f1da001df7d6f4985159d1cb53ad9 Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 12 Jul 2023 17:41:20 +0000 Subject: [PATCH 06/13] Mirror: 0.0.278 --- .version | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.version b/.version index 0d3cc30..5447725 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -0.0.277 +0.0.278 diff --git a/setup.py b/setup.py index 8726c02..aedcfaf 100644 --- a/setup.py +++ b/setup.py @@ -6,5 +6,5 @@ setup( name='pre_commit_placeholder_package', version='0.0.0', - install_requires=['ruff==0.0.277'], + install_requires=['ruff==0.0.278'], ) From e2a2094fd1ae3a4fedb7315c5379641ecf13a7fa Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 12 Jul 2023 17:41:21 +0000 Subject: [PATCH 07/13] Bump README.md version to 0.0.278 --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 5979d98..b486750 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ # ruff-pre-commit [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) -[![image](https://img.shields.io/pypi/v/ruff/0.0.277.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/l/ruff/0.0.277.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.277.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/v/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/l/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) [![Actions status](https://github.com/astral-sh/ruff-pre-commit/workflows/main/badge.svg)](https://github.com/astral-sh/ruff-pre-commit/actions) A [pre-commit](https://pre-commit.com/) hook for [Ruff](https://github.com/charliermarsh/ruff). @@ -18,7 +18,7 @@ Add this to your `.pre-commit-config.yaml`: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.277 + rev: v0.0.278 hooks: - id: ruff ``` @@ -28,7 +28,7 @@ Or, to enable autofix: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.277 + rev: v0.0.278 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] @@ -39,7 +39,7 @@ To run the hook on Jupyter Notebooks too: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.277 + rev: v0.0.278 hooks: - id: ruff types_or: [python, pyi, jupyter] From da18a96f5b4ecf263a4556896723d6cdeb2024d3 Mon Sep 17 00:00:00 2001 From: eggplants Date: Thu, 13 Jul 2023 23:59:29 +0900 Subject: [PATCH 08/13] Fix repo links (#46) ## Summary I replaced `charliermarsh/ruff` with `astral-sh/ruff`. ## Test Plan Check if the changed links are worked. --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index b486750..b79870f 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,12 @@ # ruff-pre-commit -[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) +[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) [![image](https://img.shields.io/pypi/v/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) [![image](https://img.shields.io/pypi/l/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) [![image](https://img.shields.io/pypi/pyversions/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) [![Actions status](https://github.com/astral-sh/ruff-pre-commit/workflows/main/badge.svg)](https://github.com/astral-sh/ruff-pre-commit/actions) -A [pre-commit](https://pre-commit.com/) hook for [Ruff](https://github.com/charliermarsh/ruff). +A [pre-commit](https://pre-commit.com/) hook for [Ruff](https://github.com/astral-sh/ruff). Distributed as a standalone repository to enable installing Ruff via prebuilt wheels from [PyPI](https://pypi.org/project/ruff/). @@ -56,6 +56,6 @@ MIT
- +
From b09212dc3673fc734c7279728683e89002d4a2b4 Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 21 Jul 2023 20:46:16 +0000 Subject: [PATCH 09/13] Mirror: 0.0.279 --- .version | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.version b/.version index 5447725..3a42c22 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -0.0.278 +0.0.279 diff --git a/setup.py b/setup.py index aedcfaf..549234f 100644 --- a/setup.py +++ b/setup.py @@ -6,5 +6,5 @@ setup( name='pre_commit_placeholder_package', version='0.0.0', - install_requires=['ruff==0.0.278'], + install_requires=['ruff==0.0.279'], ) From c16fde55ad87bc486b591d35ee28870a478133c8 Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 21 Jul 2023 20:46:17 +0000 Subject: [PATCH 10/13] Bump README.md version to 0.0.279 --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index b79870f..0253a4d 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ # ruff-pre-commit [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) -[![image](https://img.shields.io/pypi/v/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/l/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.278.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/v/ruff/0.0.279.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/l/ruff/0.0.279.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.279.svg)](https://pypi.python.org/pypi/ruff) [![Actions status](https://github.com/astral-sh/ruff-pre-commit/workflows/main/badge.svg)](https://github.com/astral-sh/ruff-pre-commit/actions) A [pre-commit](https://pre-commit.com/) hook for [Ruff](https://github.com/astral-sh/ruff). @@ -18,7 +18,7 @@ Add this to your `.pre-commit-config.yaml`: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.278 + rev: v0.0.279 hooks: - id: ruff ``` @@ -28,7 +28,7 @@ Or, to enable autofix: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.278 + rev: v0.0.279 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] @@ -39,7 +39,7 @@ To run the hook on Jupyter Notebooks too: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.278 + rev: v0.0.279 hooks: - id: ruff types_or: [python, pyi, jupyter] From 1c8d30bd0337717ec98f508ff8fcd12de81d3586 Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 22 Jul 2023 03:51:24 +0000 Subject: [PATCH 11/13] Mirror: 0.0.280 --- .version | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.version b/.version index 3a42c22..8146964 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -0.0.279 +0.0.280 diff --git a/setup.py b/setup.py index 549234f..3fe92e9 100644 --- a/setup.py +++ b/setup.py @@ -6,5 +6,5 @@ setup( name='pre_commit_placeholder_package', version='0.0.0', - install_requires=['ruff==0.0.279'], + install_requires=['ruff==0.0.280'], ) From 5997ecd133c20c853dcd82946a0f5467edfad463 Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 22 Jul 2023 03:51:25 +0000 Subject: [PATCH 12/13] Bump README.md version to 0.0.280 --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 0253a4d..1f96dab 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ # ruff-pre-commit [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) -[![image](https://img.shields.io/pypi/v/ruff/0.0.279.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/l/ruff/0.0.279.svg)](https://pypi.python.org/pypi/ruff) -[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.279.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/v/ruff/0.0.280.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/l/ruff/0.0.280.svg)](https://pypi.python.org/pypi/ruff) +[![image](https://img.shields.io/pypi/pyversions/ruff/0.0.280.svg)](https://pypi.python.org/pypi/ruff) [![Actions status](https://github.com/astral-sh/ruff-pre-commit/workflows/main/badge.svg)](https://github.com/astral-sh/ruff-pre-commit/actions) A [pre-commit](https://pre-commit.com/) hook for [Ruff](https://github.com/astral-sh/ruff). @@ -18,7 +18,7 @@ Add this to your `.pre-commit-config.yaml`: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.279 + rev: v0.0.280 hooks: - id: ruff ``` @@ -28,7 +28,7 @@ Or, to enable autofix: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.279 + rev: v0.0.280 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] @@ -39,7 +39,7 @@ To run the hook on Jupyter Notebooks too: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.0.279 + rev: v0.0.280 hooks: - id: ruff types_or: [python, pyi, jupyter] From 2b844a9c8b9defadd0a0fab39dace0b524999daa Mon Sep 17 00:00:00 2001 From: Github Actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 31 Jul 2023 18:21:54 +0000 Subject: [PATCH 13/13] Mirror: 0.0.281 --- .version | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.version b/.version index 8146964..5171753 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -0.0.280 +0.0.281 diff --git a/setup.py b/setup.py index 3fe92e9..11b1e3d 100644 --- a/setup.py +++ b/setup.py @@ -6,5 +6,5 @@ setup( name='pre_commit_placeholder_package', version='0.0.0', - install_requires=['ruff==0.0.280'], + install_requires=['ruff==0.0.281'], )