ó
j4Vdc           @   s&   d  Z  d d l m Z e d „ Z d S(   s0   
Console/terminal user interface functionality.
iÿÿÿÿ(   t   promptc         C   sq   | r d } n d } xU t  rl t d |  | f ƒ j ƒ  } | sD | S| d
 k rT t  S| d k rd t Sd GHq Wd	 S(   sÔ  
    Ask user a yes/no question and return their response as True or False.

    ``question`` should be a simple, grammatically complete question such as
    "Do you wish to continue?", and will have a string similar to " [Y/n] "
    appended automatically. This function will *not* append a question mark for
    you.

    By default, when the user presses Enter without typing anything, "yes" is
    assumed. This can be changed by specifying ``default=False``.
    s   Y/ns   y/Ns   %s [%s] t   yt   yest   nt   nos:   I didn't understand you. Please specify '(y)es' or '(n)o'.N(   R   R   (   R   R   (   t   TrueR    t   lowert   False(   t   questiont   defaultt   suffixt   response(    (    sd   /var/www/html/phendo-backend/phendo_python/env/lib/python2.7/site-packages/fabric/contrib/console.pyt   confirm   s    		N(   t   __doc__t
   fabric.apiR    R   R   (    (    (    sd   /var/www/html/phendo-backend/phendo_python/env/lib/python2.7/site-packages/fabric/contrib/console.pyt   <module>   s   