File: //usr/lib/python3.9/site-packages/pip/_internal/commands/__pycache__/uninstall.cpython-39.pyc
a
?�f� � @ s� d dl mZ d dlmZ d dlmZ d dlmZ d dlm Z d dl
mZ d dlm
Z
d dlmZmZ d d lmZ d d
lmZ er�d dlmZ d dlmZ G d
d� dee�ZdS )� )�absolute_import)�canonicalize_name)�Command)�SessionCommandMixin)�SUCCESS)�InstallationError)�parse_requirements)�install_req_from_line�#install_req_from_parsed_requirement)�(protect_pip_from_modification_on_windows)�MYPY_CHECK_RUNNING)�Values)�Listc @ s$ e Zd ZdZdZdd� Zdd� ZdS )�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> ...c 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_optionsc
C s� | � |�}i }|D ]&}t||jd�}|jr||t|j�<