Add and prefer the ruff-check
pre-commit ID (#124)
## Summary Towards #123. Introduces the `ruff-check` pre-commit hook ID, updates documentation to prefer it, but retains the `ruff` ID for compatibility.
This commit is contained in:
parent
24e02b24b8
commit
39f54b73c7
@ -1,6 +1,6 @@
|
|||||||
- id: ruff
|
- id: ruff-check
|
||||||
name: ruff
|
name: ruff check
|
||||||
description: "Run 'ruff' for extremely fast Python linting"
|
description: "Run 'ruff check' for extremely fast Python linting"
|
||||||
entry: ruff check --force-exclude
|
entry: ruff check --force-exclude
|
||||||
language: python
|
language: python
|
||||||
types_or: [python, pyi, jupyter]
|
types_or: [python, pyi, jupyter]
|
||||||
@ -10,7 +10,7 @@
|
|||||||
minimum_pre_commit_version: "2.9.2"
|
minimum_pre_commit_version: "2.9.2"
|
||||||
|
|
||||||
- id: ruff-format
|
- id: ruff-format
|
||||||
name: ruff-format
|
name: ruff format
|
||||||
description: "Run 'ruff format' for extremely fast Python formatting"
|
description: "Run 'ruff format' for extremely fast Python formatting"
|
||||||
entry: ruff format --force-exclude
|
entry: ruff format --force-exclude
|
||||||
language: python
|
language: python
|
||||||
@ -19,3 +19,15 @@
|
|||||||
require_serial: true
|
require_serial: true
|
||||||
additional_dependencies: []
|
additional_dependencies: []
|
||||||
minimum_pre_commit_version: "2.9.2"
|
minimum_pre_commit_version: "2.9.2"
|
||||||
|
|
||||||
|
# Legacy alias
|
||||||
|
- id: ruff
|
||||||
|
name: ruff (legacy alias)
|
||||||
|
description: "Run 'ruff check' for extremely fast Python linting"
|
||||||
|
entry: ruff check --force-exclude
|
||||||
|
language: python
|
||||||
|
types_or: [python, pyi, jupyter]
|
||||||
|
args: []
|
||||||
|
require_serial: true
|
||||||
|
additional_dependencies: []
|
||||||
|
minimum_pre_commit_version: "2.9.2"
|
||||||
|
@ -23,7 +23,7 @@ repos:
|
|||||||
rev: v0.11.9
|
rev: v0.11.9
|
||||||
hooks:
|
hooks:
|
||||||
# Run the linter.
|
# Run the linter.
|
||||||
- id: ruff
|
- id: ruff-check
|
||||||
# Run the formatter.
|
# Run the formatter.
|
||||||
- id: ruff-format
|
- id: ruff-format
|
||||||
```
|
```
|
||||||
@ -37,7 +37,7 @@ repos:
|
|||||||
rev: v0.11.9
|
rev: v0.11.9
|
||||||
hooks:
|
hooks:
|
||||||
# Run the linter.
|
# Run the linter.
|
||||||
- id: ruff
|
- id: ruff-check
|
||||||
args: [ --fix ]
|
args: [ --fix ]
|
||||||
# Run the formatter.
|
# Run the formatter.
|
||||||
- id: ruff-format
|
- id: ruff-format
|
||||||
@ -52,7 +52,7 @@ repos:
|
|||||||
rev: v0.11.9
|
rev: v0.11.9
|
||||||
hooks:
|
hooks:
|
||||||
# Run the linter.
|
# Run the linter.
|
||||||
- id: ruff
|
- id: ruff-check
|
||||||
types_or: [ python, pyi ]
|
types_or: [ python, pyi ]
|
||||||
args: [ --fix ]
|
args: [ --fix ]
|
||||||
# Run the formatter.
|
# Run the formatter.
|
||||||
|
Loading…
Reference in New Issue
Block a user