관리-도구
편집 파일: uninstall.cpython-39.pyc
a ����[��f� ����������������������@���s����d�dl�Z�d�dlmZ�d�dlmZ�d�dlmZ�d�dlmZ�d�dl m Z mZ�d�dlm Z �d�dlmZ�d�d lmZ�d�d lmZmZ�d�dlmZ�e��e�ZG�dd ��d ee �ZdS�)�����N)�Values)�List)�canonicalize_name)�Command)�SessionCommandMixin�warn_if_run_as_root)�SUCCESS)�InstallationError)�parse_requirements)�install_req_from_line�#install_req_from_parsed_requirement)�(protect_pip_from_modification_on_windowsc�������������������@���s8���e�Zd�ZdZdZdd�dd�Zeee�e d�dd �Z dS�) �UninstallCommandaB�� Uninstall packages. pip is able to uninstall most installed packages. Known exceptions are: - Pure distutils packages installed with ``python setup.py install``, which leave behind no metadata to determine what files were installed. - Script wrappers installed by ``python setup.py develop``. zU %prog [options] <package> ... %prog [options] -r <requirements file> ...N)�returnc�������������� ���C���sD���|�j�jddddg�ddd��|�j�jdd d ddd ��|�j�d|�j���d�S�)Nz-rz --requirement�requirements�append�filezjUninstall all the packages listed in the given requirements file. This option can be used multiple times.)�dest�action�default�metavar�helpz-yz--yes�yes� store_truez2Don't ask for confirmation of uninstall deletions.)r���r���r���r���)Zcmd_optsZ add_option�parserZinsert_option_group)�self��r����D/usr/lib/python3.9/site-packages/pip/_internal/commands/uninstall.py�add_options$���s"������zUninstallCommand.add_options)�options�argsr���c����������� ������C���s����|���|�}i�}|D�]4}t||jd�}|jr:||t|j�<�qt�d|��q|jD�]:}t|||d�D�]&}t ||jd�}|jr`||t|j�<�q`qN|s�t d|�j��d|�j��d���td|v�d��|���D�]&}|j |j|�jd kd �} | r�| ����q�t���tS�)N)�isolatedzSInvalid requirement: %r ignored - the uninstall command expects named requirements.)r����sessionz*You must give at least one requirement to z (see "pip help z")Zpip)Z modifying_pipr���)Zauto_confirm�verbose)Zget_default_sessionr���Z isolated_mode�namer����loggerZwarningr���r ���r���r ���r ����valuesZ uninstallr���� verbosityZcommitr���r���) r���r���r ���r"���Zreqs_to_uninstallr$���Zreq�filenameZ parsed_reqZuninstall_pathsetr���r���r����run;���sP���� �� � � ���� zUninstallCommand.run)�__name__� __module__�__qualname__�__doc__�usager���r���r����str�intr)���r���r���r���r���r������s��� r���)ZloggingZoptparser����typingr���Zpip._vendor.packaging.utilsr���Zpip._internal.cli.base_commandr���Zpip._internal.cli.req_commandr���r���Zpip._internal.cli.status_codesr���Zpip._internal.exceptionsr ���Zpip._internal.reqr ���Zpip._internal.req.constructorsr���r���Zpip._internal.utils.miscr ���Z getLoggerr*���r%���r���r���r���r���r����<module>���s���