Better source-exclude reference docs (#16832)

Fixed https://github.com/astral-sh/uv/issues/16821

This is already explained in the guide, but it was missing from the
reference docs.

---------

Co-authored-by: Zanie Blue <contact@zanie.dev>
This commit is contained in:
konsti 2025-12-09 22:14:28 +01:00 committed by GitHub
parent b6686fbce3
commit 8d2c2e8cdf
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 5 additions and 2 deletions

View File

@ -70,6 +70,9 @@ pub struct BuildBackendSettings {
pub default_excludes: bool,
/// Glob expressions which files and directories to exclude from the source distribution.
///
/// These exclusions are also applied to wheels to ensure that a wheel built from a source tree
/// is consistent with a wheel built from a source distribution.
#[option(
default = r#"[]"#,
value_type = "list[str]",

View File

@ -230,7 +230,7 @@ From these,
[`tool.uv.build-backend.source-exclude`](../reference/settings.md#build-backend_source-exclude),
[`tool.uv.build-backend.wheel-exclude`](../reference/settings.md#build-backend_wheel-exclude) and
the default excludes are removed. The source dist excludes are applied to avoid source tree to wheel
source builds including more files than source tree to source distribution to wheel build.
builds including more files than source tree to source distribution to wheel build.
There are no specific wheel includes. There must only be one top level module, and all data files
must either be under the module root or in the appropriate

2
uv.schema.json generated
View File

@ -744,7 +744,7 @@
"default": false
},
"source-exclude": {
"description": "Glob expressions which files and directories to exclude from the source distribution.",
"description": "Glob expressions which files and directories to exclude from the source distribution.\n\nThese exclusions are also applied to wheels to ensure that a wheel built from a source tree\nis consistent with a wheel built from a source distribution.",
"type": "array",
"default": [],
"items": {