Skip to content

uv self update should support --dry-run #9828

@jmknoble

Description

@jmknoble

I want uv to tell me whether it thinks it needs an update, before I actually tell it to update.

The most straightforward pattern for this would seem to be supporting --dry-run (which uv lock already supports). uv self update doen't currently support that:

$ uv --version
uv 0.5.7 (3ca155ddd 2024-12-06)
$ uv self update --dry-run
error: unexpected argument '--dry-run' found

  tip: to pass '--dry-run' as a value, use '-- --dry-run'

Usage: uv self update [OPTIONS] [TARGET_VERSION]

For more information, try '--help'.
$ uv --dry-run self update
error: unexpected argument '--dry-run' found

Usage: uv [OPTIONS] <COMMAND>

For more information, try '--help'.
$ 

Possible alternatives:

  • uv self list-updates (clunky?)
  • uv self update list (ripe for human error)
  • uv self update --list (ditto)
  • uv self list (better, more like uv python list, may need uv self install too? (and maybe uv python update should be a command as well?))
  • uv self versions (different name, same action as uv self list, no real precedent though)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or improvement to existing functionality

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions