Skip to content

Commit

Permalink
Replace black with ruff-format in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
melissawm committed Oct 23, 2024
1 parent d712b1d commit ebff1e5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
8 changes: 3 additions & 5 deletions docs/developers/contributing/dev_install.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ In order to make changes to `napari`, you will need to [fork](https://docs.githu
Note that in this last case you will need to install your Qt backend separately.
5. We use [`pre-commit`](https://pre-commit.com) to format code with
[`black`](https://github.com/psf/black) and lint with
[`ruff-format`](https://docs.astral.sh/ruff/formatter/) and lint with
[`ruff`](https://github.com/astral-sh/ruff) automatically prior to each commit.
To minimize test errors when submitting pull requests, please install `pre-commit`
in your environment as follows:
Expand All @@ -82,10 +82,8 @@ In order to make changes to `napari`, you will need to [fork](https://docs.githu
pre-commit install
```
Upon committing, your code will be formatted according to our [`black`
configuration](https://github.com/napari/napari/blob/main/pyproject.toml), which includes the settings
`skip-string-normalization = true` and `max-line-length = 79`. To learn more,
see [`black`'s documentation](https://black.readthedocs.io/en/stable/).
Upon committing, your code will be formatted according to our [`ruff-format`
configuration](https://github.com/napari/napari/blob/main/pyproject.toml).
Code will also be linted to enforce the stylistic and logistical rules specified
in the `[tool.ruff]` section of
Expand Down
2 changes: 1 addition & 1 deletion docs/developers/coredev/core_dev_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ As a core member, you should be familiar with the following napari guides:
[NumPy documentation guide](https://numpy.org/devdocs/dev/howto-docs.html#documentation-style)
for docstring conventions.
- [`pre-commit`](https://pre-commit.com) hooks for autoformatting.
- [`black`](https://github.com/psf/black) autoformatting.
- [`ruff-format`](https://docs.astral.sh/ruff/formatter/) autoformatting.
- [`ruff`](https://github.com/astral-sh/ruff) linting.

### Social resources
Expand Down

0 comments on commit ebff1e5

Please sign in to comment.