uv icon indicating copy to clipboard operation
uv copied to clipboard

Add `pip cache info` and `pip cache list`

Open hugovk opened this issue 1 year ago • 0 comments

Follow on from https://github.com/astral-sh/uv/issues/1646#issuecomment-1951356710.

It would be useful to add something like pip cache info, because we will end up with large pip and uv caches on some systems:

❯ pip cache info
Package index page cache location (pip v23.3+): /Users/hugo/Library/Caches/pip/http-v2
Package index page cache location (older pips): /Users/hugo/Library/Caches/pip/http
Package index page cache size: 187.6 MB
Number of HTTP files: 870
Locally built wheels location: /Users/hugo/Library/Caches/pip/wheels
Locally built wheels size: 5.9 MB
Number of locally built wheels: 10

Something like pip cache list could be useful too (it's normally much bigger than this, but I recently did pip cache clear!):

❯ pip cache list
Cache contents:

 - MarkupSafe-2.1.5-cp313-cp313d-macosx_14_0_arm64.whl (15 kB)
 - cffi-1.16.0-cp38-cp38-macosx_11_0_universal2.whl (256 kB)
 - coverage-7.4.1-cp313-cp313d-macosx_14_0_arm64.whl (208 kB)
 - pillow-10.3.0.dev0-cp312-cp312-macosx_10_9_universal2.whl (888 kB)
 - pip-24.1.dev0-py3-none-any.whl (2.1 MB)
 - pip-24.1.dev0-py3-none-any.whl (2.1 MB)
 - scripttest-1.3-py3-none-any.whl (7.8 kB)
 - simple-1.0-py3-none-any.whl (1.1 kB)
 - simple2-3.0-py3-none-any.whl (1.1 kB)
 - tinytext-3.6.1.dev64-py3-none-any.whl (4.4 kB)

hugovk avatar Feb 18 '24 15:02 hugovk