7iddlZddlZddlmZddlmZmZddlmZddl m Z m Z ddl m Z mZddlmZddlmZeeZGd d eZy) N)Values)AnyList)Command)ERRORSUCCESS) CommandErrorPipError) filesystem) getLoggerc,eZdZdZdZdZddZdedee de fd Z dedee ddfd Z dedee ddfd Zdedee ddfd Zd ee ddfdZd ee ddfdZdedee ddfdZdedee ddfdZdede de fdZdedee fdZdede dee fdZy) CacheCommandaw Inspect and manage pip's wheel cache. Subcommands: - dir: Show the cache directory. - info: Show information about the cache. - list: List filenames of packages stored in the cache. - remove: Remove one or more package from the cache. - purge: Remove all items from the cache. ```` can be a glob expression or a package name. Tz %prog dir %prog info %prog list [] [--format=[human, abspath]] %prog remove %prog purge returnNc|jjdddddd|jjd|jy) Nz--formatstore list_formathuman)rabspathz:Select the output format among: human (default) or abspath)actiondestdefaultchoiceshelpr)cmd_opts add_optionparserinsert_option_group)selfs e/mnt/ssd/data/python-lab/ChefSystem/venv/lib/python3.12/site-packages/pip/_internal/commands/cache.py add_optionszCacheCommand.add_options'sE   (M !  ''4==9optionsargsc|j|j|j|j|jd}|j st jdtS|r|d|vr4t jddjt|tS|d} ||||ddtS#t$r2}t j|jdtcYd}~Sd}~wwxYw)N)dirinfolistremovepurgez T**73 3E Qy: :O NN? + 3H IIh  NN< 2 3  'U4r!cB|r td|j|dgS)Nr9r<)r r.r:s rr/zCacheCommand.purge_caches& 34 4&&w66r!subdircVtjj|j|S)N)r\r]r3r0)rr"rms rrJzCacheCommand._cache_dirsww||G--v66r!c|j|d}|j|d}tj|dtj|dzS)Nr>r=r<rJr find_files)rr" old_http_dir new_http_dirs rrHzCacheCommand._find_http_filessNw7 w : $$\37*:O:O #;   r!rWch|j|d}|d|vrdndz}tj||S)Nr?-z*.whlz-*.whlrp)rr"rW wheel_dirs rrIzCacheCommand._find_wheelss9OOGX6 $wWHE$$Y88r!)rN)__name__ __module__ __qualname____doc__ignore_require_venvusager rrstrintr7rr+r,r-rUrVr.r/rJrHrIr!rrrsN  E :6cs@'V'49'' (f(DI($(T + +d3i +D + 0d3i 0D 02S 2d25&5S 5d52767c7t7 7&7#7#7  49 9F9S9T#Y9r!r)r\rNoptparsertypingrrpip._internal.cli.base_commandrpip._internal.cli.status_codesrrpip._internal.exceptionsr r pip._internal.utilsr pip._internal.utils.loggingr rwr1rrr!rrs8 29;*1 8 R97R9r!