uv icon indicating copy to clipboard operation
uv copied to clipboard

Show tool versions in `uv tool list`

Open zanieb opened this issue 1 year ago • 6 comments

In addition to the name, it'd be nice to show the installed version. Should this be behind a flag? Are there other commands like uv pip list or pipx list we should take inspiration from?

A simple example:

$ uv tool list --show-versions
black v20.0.1

Related:

  • #4654

zanieb avatar Jun 29 '24 22:06 zanieb

The cargo command which includes both the version and entrypoints could be used as an inspiration too.

❯ cargo install --list
sqlx-cli v0.7.3:
    cargo-sqlx
    sqlx

blueraft avatar Jun 30 '24 09:06 blueraft

Nice, I like the look of that

zanieb avatar Jun 30 '24 14:06 zanieb

I think the version should be showed by default because it doesn't add that much of information, the entrypoints maybe we should add a flag like --entrypoints because for cases where we have a lot of tools it might be too much

caiquejjx avatar Jun 30 '24 16:06 caiquejjx

Personally I'd probably do:

sqlx-cli==0.7.3:
    cargo-sqlx
    sqlx

Only because sqlx-cli==0.7.3 matches pip freeze. But I don't feel strongly.

charliermarsh avatar Jun 30 '24 20:06 charliermarsh

I don't love the pinned requirement syntax for something that will always be a specific version and isn't meant for consumption by another tool.

zanieb avatar Jun 30 '24 22:06 zanieb

I have created a pr based on @blueraft suggestion, lmk if it is the final design we want

caiquejjx avatar Jul 01 '24 00:07 caiquejjx