mirror of
https://github.com/astral-sh/uv.git
synced 2025-11-25 05:33:43 +00:00
Add PEP 751 support to uv pip compile (#13019)
## Summary You now specify `--format pylock.toml` or `-o pylock.toml` to output in PEP 751 format.
This commit is contained in:
parent
b594c2d702
commit
2ba4edfbbe
14 changed files with 1547 additions and 125 deletions
|
|
@ -1075,13 +1075,22 @@ pub struct PipCompileArgs {
|
|||
#[arg(long, group = "sources")]
|
||||
pub group: Vec<PipGroupName>,
|
||||
|
||||
/// Write the compiled requirements to the given `requirements.txt` file.
|
||||
/// Write the compiled requirements to the given `requirements.txt` or `pylock.toml` file.
|
||||
///
|
||||
/// If the file already exists, the existing versions will be preferred when resolving
|
||||
/// dependencies, unless `--upgrade` is also specified.
|
||||
#[arg(long, short)]
|
||||
pub output_file: Option<PathBuf>,
|
||||
|
||||
/// The format in which the resolution should be output.
|
||||
///
|
||||
/// Supports both `requirements.txt` and `pylock.toml` (PEP 751) output formats.
|
||||
///
|
||||
/// uv will infer the output format from the file extension of the output file, if
|
||||
/// provided. Otherwise, defaults to `requirements.txt`.
|
||||
#[arg(long, value_enum)]
|
||||
pub format: Option<ExportFormat>,
|
||||
|
||||
/// Include extras in the output file.
|
||||
///
|
||||
/// By default, uv strips extras, as any packages pulled in by the extras are already included
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue