ó
'šMc           @   s]   d  d l  m Z m Z m Z d  d l m Z d  d l m Z d e f d „  ƒ  YZ e ƒ  d S(   iÿÿÿÿ(   t   InstallRequirementt   RequirementSett   parse_requirements(   t   Command(   t   InstallationErrort   UninstallCommandc           B   s,   e  Z d  Z d Z d Z d „  Z d „  Z RS(   t	   uninstalls!   %prog [OPTIONS] PACKAGE_NAMES ...s   Uninstall packagesc         C   sm   t  t |  ƒ j ƒ  |  j j d d d d d d d g  d d	 d
 d ƒ|  j j d d d d d d d
 d ƒd  S(   Ns   -rs   --requirementt   destt   requirementst   actiont   appendt   defaultt   metavart   FILENAMEt   helpsj   Uninstall all the packages listed in the given requirements file.  This option can be used multiple times.s   -ys   --yest   yest
   store_trues2   Don't ask for confirmation of uninstall deletions.(   t   superR   t   __init__t   parsert
   add_option(   t   self(    (    s:   /usr/lib/python2.7/dist-packages/pip/commands/uninstall.pyR   
   s    				c         C   s¿   t  d d  d d  d d  ƒ } x$ | D] } | j t j | ƒ ƒ q" Wx; | j D]0 } x' t | d | ƒD] } | j | ƒ qe WqL W| j s¨ t d t	 d |  j
 ƒ ƒ ‚ n  | j d | j ƒ d  S(   Nt	   build_dirt   src_dirt   download_dirt   optionssL   You must give at least one requirement to %(name)s (see "pip help %(name)s")t   namet   auto_confirm(   R   t   Nonet   add_requirementR    t	   from_lineR   R   t   has_requirementsR   t   dictR   R   R   (   R   R   t   argst   requirement_setR   t   filenamet   req(    (    s:   /usr/lib/python2.7/dist-packages/pip/commands/uninstall.pyt   run   s    		(   t   __name__t
   __module__R   t   usaget   summaryR   R%   (    (    (    s:   /usr/lib/python2.7/dist-packages/pip/commands/uninstall.pyR      s
   	N(	   t   pip.reqR    R   R   t   pip.basecommandR   t   pip.exceptionsR   R   (    (    (    s:   /usr/lib/python2.7/dist-packages/pip/commands/uninstall.pyt   <module>   s   %