mirror of
https://github.com/astral-sh/uv.git
synced 2025-08-04 19:08:04 +00:00
Add support for locking PEP 723 scripts (#10135)
## Summary You can now run `uv lock --script main.py` to lock a given script (though as of this PR, the script itself isn't used anywhere). Closes https://github.com/astral-sh/uv/issues/6318.
This commit is contained in:
parent
2f7f9ea571
commit
5d33b94c42
7 changed files with 434 additions and 23 deletions
|
@ -2135,6 +2135,10 @@ uv lock [OPTIONS]
|
|||
|
||||
<li><code>lowest-direct</code>: Resolve the lowest compatible version of any direct dependencies, and the highest compatible version of any transitive dependencies</li>
|
||||
</ul>
|
||||
</dd><dt><code>--script</code> <i>script</i></dt><dd><p>Lock the specified Python script, rather than the current project.</p>
|
||||
|
||||
<p>If provided, uv will lock the script (based on its inline metadata table, in adherence with PEP 723) to a <code>.lock</code> file adjacent to the script itself.</p>
|
||||
|
||||
</dd><dt><code>--upgrade</code>, <code>-U</code></dt><dd><p>Allow package upgrades, ignoring pinned versions in any existing output file. Implies <code>--refresh</code></p>
|
||||
|
||||
</dd><dt><code>--upgrade-package</code>, <code>-P</code> <i>upgrade-package</i></dt><dd><p>Allow upgrades for a specific package, ignoring pinned versions in any existing output file. Implies <code>--refresh-package</code></p>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue