mirror of https://github.com/astral-sh/ruff
Fix typo in src option docs (#2201)
This commit is contained in:
parent
f3aa409d9a
commit
0ad6b8224d
|
|
@ -2443,7 +2443,7 @@ my_package/
|
||||||
bar.py
|
bar.py
|
||||||
```
|
```
|
||||||
|
|
||||||
The `src` directory should be included in `source` (e.g., `source =
|
The `src` directory should be included in the `src` option (e.g., `src =
|
||||||
["src"]`), such that when resolving imports, `my_package.foo` is
|
["src"]`), such that when resolving imports, `my_package.foo` is
|
||||||
considered a first-party import.
|
considered a first-party import.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -421,7 +421,7 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"src": {
|
"src": {
|
||||||
"description": "The source code paths to consider, e.g., when resolving first- vs. third-party imports.\n\nAs an example: given a Python package structure like:\n\n```text my_package/ pyproject.toml src/ my_package/ __init__.py foo.py bar.py ```\n\nThe `src` directory should be included in `source` (e.g., `source = [\"src\"]`), such that when resolving imports, `my_package.foo` is considered a first-party import.\n\nThis field supports globs. For example, if you have a series of Python packages in a `python_modules` directory, `src = [\"python_modules/*\"]` would expand to incorporate all of the packages in that directory. User home directory and environment variables will also be expanded.",
|
"description": "The source code paths to consider, e.g., when resolving first- vs. third-party imports.\n\nAs an example: given a Python package structure like:\n\n```text my_package/ pyproject.toml src/ my_package/ __init__.py foo.py bar.py ```\n\nThe `src` directory should be included in the `src` option (e.g., `src = [\"src\"]`), such that when resolving imports, `my_package.foo` is considered a first-party import.\n\nThis field supports globs. For example, if you have a series of Python packages in a `python_modules` directory, `src = [\"python_modules/*\"]` would expand to incorporate all of the packages in that directory. User home directory and environment variables will also be expanded.",
|
||||||
"type": [
|
"type": [
|
||||||
"array",
|
"array",
|
||||||
"null"
|
"null"
|
||||||
|
|
|
||||||
|
|
@ -342,7 +342,7 @@ pub struct Options {
|
||||||
/// bar.py
|
/// bar.py
|
||||||
/// ```
|
/// ```
|
||||||
///
|
///
|
||||||
/// The `src` directory should be included in `source` (e.g., `source =
|
/// The `src` directory should be included in the `src` option (e.g., `src =
|
||||||
/// ["src"]`), such that when resolving imports, `my_package.foo` is
|
/// ["src"]`), such that when resolving imports, `my_package.foo` is
|
||||||
/// considered a first-party import.
|
/// considered a first-party import.
|
||||||
///
|
///
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue