Use a separate repo for pre-commit (#229)

This commit is contained in:
Charlie Marsh 2022-09-19 21:06:39 -06:00 committed by GitHub
parent fa0954fe47
commit 27cc7e236c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 13 deletions

View file

@ -1,5 +1,5 @@
repos:
- repo: https://github.com/charliermarsh/ruff
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.0.40
hooks:
- id: lint

View file

@ -1,7 +0,0 @@
- id: lint
name: ruff lint
description: Run ruff to lint Python files.
entry: ruff
language: python
types_or: [python]
pass_filenames: true

View file

@ -54,14 +54,14 @@ You can run ruff in `--watch` mode to automatically re-run on-change:
ruff path/to/code/ --watch
```
ruff also works with [Pre-Commit](https://pre-commit.com) (requires Cargo on system):
ruff also works with [pre-commit](https://pre-commit.com):
```yaml
repos:
- repo: https://github.com/charliermarsh/ruff
rev: v0.0.40
hooks:
- id: lint
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.0.40
hooks:
- id: lint
```
## Configuration