Add Python implementation example to limited resolution environments docs (#9475)

Closes https://github.com/astral-sh/uv/issues/9473
This commit is contained in:
Zanie Blue 2024-11-27 09:53:39 -06:00 committed by GitHub
parent 6afb34091c
commit 7df3ae2585
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -185,6 +185,15 @@ environments = [
]
```
Or, to exclude alternative Python implementations:
```toml title="pyproject.toml"
[tool.uv]
environments = [
"implementation_name == 'cpython'"
]
```
Entries in the `environments` setting must be disjoint (i.e., they must not overlap). For example,
`sys_platform == 'darwin'` and `sys_platform == 'linux'` are disjoint, but
`sys_platform == 'darwin'` and `python_version >= '3.9'` are not, since both could be true at the