mirror of
https://github.com/astral-sh/uv.git
synced 2025-08-31 07:47:27 +00:00
Note that uv lock --upgrade-package
retains locked versions (#7694)
Closes https://github.com/astral-sh/uv/issues/7672.
This commit is contained in:
parent
cc2aa8855a
commit
a3abd89ab0
2 changed files with 11 additions and 1 deletions
|
@ -381,7 +381,8 @@ To upgrade all packages:
|
|||
$ uv lock --upgrade
|
||||
```
|
||||
|
||||
To upgrade a single package to the latest version:
|
||||
To upgrade a single package to the latest version, while retaining the locked versions of all other
|
||||
packages:
|
||||
|
||||
```console
|
||||
$ uv lock --upgrade-package <package>
|
||||
|
|
|
@ -133,6 +133,15 @@ To remove a package, you can use `uv remove`:
|
|||
$ uv remove requests
|
||||
```
|
||||
|
||||
To upgrade a package, run `uv lock` with the `--upgrade-package` flag:
|
||||
|
||||
```console
|
||||
$ uv lock --upgrade-package requests
|
||||
```
|
||||
|
||||
The `--upgrade-package` flag will attempt to update the specified package to the latest compatible
|
||||
version, while keeping the rest of the lockfile intact.
|
||||
|
||||
See the documentation on [managing dependencies](../concepts/projects.md#managing-dependencies) for
|
||||
more details.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue