mirror of
https://github.com/astral-sh/ruff.git
synced 2025-11-01 20:31:57 +00:00
Fix typo (#8309)
<!-- Thank you for contributing to Ruff! To help us out with reviewing, please consider the following: - Does this pull request include a summary of the change? (See below.) - Does this pull request include a descriptive title? - Does this pull request include references to any relevant issues? --> ## Summary <!-- What's the purpose of the change? What does it do, and why? --> ## Test Plan <!-- How was it tested? -->
This commit is contained in:
parent
aa90a425e0
commit
87772c2884
3 changed files with 4 additions and 4 deletions
|
|
@ -114,7 +114,7 @@ such that all crates are contained in a flat `crates` directory.
|
|||
The vast majority of the code, including all lint rules, lives in the `ruff` crate (located at
|
||||
`crates/ruff_linter`). As a contributor, that's the crate that'll be most relevant to you.
|
||||
|
||||
At time of writing, the repository includes the following crates:
|
||||
At the time of writing, the repository includes the following crates:
|
||||
|
||||
- `crates/ruff_linter`: library crate containing all lint rules and the core logic for running them.
|
||||
If you're working on a rule, this is the crate for you.
|
||||
|
|
@ -877,5 +877,5 @@ By default, `src` is set to the project root. In the above example, we'd want to
|
|||
`src = ["./src"]` to ensure that we locate `./my_project/src/foo` and thus categorize `import foo`
|
||||
as first-party in `baz.py`. In practice, for this limited example, setting `src = ["./src"]` is
|
||||
unnecessary, as all imports within `./my_project/src/foo` would be categorized as first-party via
|
||||
the same-package heuristic; but your project contains multiple packages, you'll want to set `src`
|
||||
the same-package heuristic; but if your project contains multiple packages, you'll want to set `src`
|
||||
explicitly.
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ Similarly, it would _not_ be enabled via the `ALL` selector:
|
|||
select = ["ALL"]
|
||||
```
|
||||
|
||||
However, it would be enabled in any of the above cases if you you enabled preview in your configuration file:
|
||||
However, it would be enabled in any of the above cases if you enabled preview in your configuration file:
|
||||
|
||||
```toml
|
||||
[tool.ruff]
|
||||
|
|
|
|||
|
|
@ -251,7 +251,7 @@ For more in-depth instructions on ignoring errors, please see [_Error suppressio
|
|||
When enabling a new rule on an existing codebase, you may want to ignore all _existing_
|
||||
violations of that rule and instead focus on enforcing it going forward.
|
||||
|
||||
Ruff enables this workflow via the `--add-noqa` flag, which will adds a `# noqa` directive to each
|
||||
Ruff enables this workflow via the `--add-noqa` flag, which will add a `# noqa` directive to each
|
||||
line based on its existing violations. We can combine `--add-noqa` with the `--select` command-line
|
||||
flag to add `# noqa` directives to all existing `UP035` violations:
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue