astral-sh / astral-sh/ruff-pre-commit
--range support
- Dominant language
- Python
- Stars
- 2k
- Forks
- 105
- Avg merge
- 8h 36m
- Merged PRs (30d)
- 1
Description
Ruff introduced a new parameter `--range` that allows the formatter to only check the specified range. This would be useful to allow migrating from black to ruff formatting without causing whole-file diffs whenever a file is touched for the first time.
Quote from docs:
```
Editor options:
--range When specified, Ruff will try to only format the code in
the given range.
It might be necessary to extend the start backwards or
the end forwards, to fully enclose a logical line.
The `` uses the format
`:-:`.
```
Is there a way to have range support within the pre-commit framework?
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.