ok

Mini Shell

Direktori : /proc/self/root/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/
Upload File :
Current File : //proc/self/root/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyc

�
Bu�_c@@s�ddlmZddlZddlZddlZddljjjZddl	m
Z
ddlmZm
Z
ddlmZmZddlmZer�ddlmZddlmZmZneje�Zd	e
fd
��YZdS(i(tabsolute_importN(tCommand(tERRORtSUCCESS(tCommandErrortPipError(tMYPY_CHECK_RUNNING(tValues(tAnytListtCacheCommandcB@sbeZdZeZdZd�Zd�Zd�Zd�Z	d�Z
d�Zd�Zd	�Z
RS(
sw
    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.

    ``<pattern>`` can be a glob expression or a package name.
    s|
        %prog dir
        %prog info
        %prog list [<pattern>]
        %prog remove <pattern>
        %prog purge
    cC@s�i|jd6|jd6|jd6|jd6|jd6}|jsRtjd�tS|si|d|kr�tjdd	j	t
|���tS|d}y||||d
�Wn(tk
r�}tj|jd�tSXt
S(Ntdirtinfotlisttremovetpurges<pip cache commands can not function since cache is disabled.isNeed an action (%s) to perform.s, i(t
get_cache_dirtget_cache_infotlist_cache_itemstremove_cache_itemstpurge_cachet	cache_dirtloggerterrorRtjointsortedRtargsR(tselftoptionsRthandlerstactionte((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pytrun-s*




	

cC@s)|rtd��ntj|j�dS(NsToo many arguments(RRRR(RRR((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyROscC@s�|rtd��nt|j|d��}|j|�}tj|�}tjd�jd|d|d|�j	�}t
j|�dS(NsToo many argumentst*sq
            Location: {location}
            Size: {size}
            Number of wheels: {package_count}
        tlocationt
package_counttsize(Rtlent_find_wheelst_wheels_cache_dirt
filesystemtformat_directory_sizettextwraptdedenttformattstripRR(RRRtnum_packagestcache_locationt
cache_sizetmessage((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyRVsc	C@s�t|�dkr!td��n|r4|d}nd}|j||�}|sctjd�dSg}xH|D]@}tjj|�}tj	|�}|j
dj||��qpWtjd�tjdjt
|���dS(	NisToo many argumentsiR!sNothing cached.s
 - {} ({})sCache contents:
s
(R%RR&RRtostpathtbasenameR(tformat_file_sizetappendR,RR(	RRRtpatterntfilestresultstfilenametwheelR$((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyRls 



cC@s�t|�dkr!td��n|s6td��n|j||d�}|satd��nx+|D]#}tj|�tjd|�qhWtjdt|��dS(NisToo many argumentssPlease provide a patternisNo matching packagess
Removed %ssFiles removed: %s(R%RR&R2tunlinkRtdebugR(RRRR8R:((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyR�s

cC@s(|rtd��n|j|dg�S(NsToo many argumentsR!(RR(RRR((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyR�scC@stjj|jd�S(Ntwheels(R2R3RR(RR((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyR'�scC@s;|j|�}|d|kr$dnd}tj||�S(Nt-s*.whls-*.whl(R'R(t
find_files(RRR7t	wheel_dir((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyR&�s(t__name__t
__module__t__doc__tTruetignore_require_venvtusageR RRRRRR'R&(((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyR
s
	"						(t
__future__RtloggingR2R*tpip._internal.utils.filesystemt	_internaltutilsR(tpip._internal.cli.base_commandRtpip._internal.cli.status_codesRRtpip._internal.exceptionsRRtpip._internal.utils.typingRtoptparseRttypingRR	t	getLoggerRBRR
(((sM/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/commands/cache.pyt<module>s

Zerion Mini Shell 1.0