Edit File: baseparser.pyo
� ��abc�����������@@��s1��d��Z��d�d�l�m�Z�d�d�l�Z�d�d�l�Z�d�d�l�Z�d�d�l�Z�d�d�l�Z�d�d�l�m �Z �d�d�l �m�Z�d�d�l�m �Z �d�d�l�m�Z�m�Z�m�Z�m�Z�d�d�l�m�Z�m�Z�e�j�d �e�j���Z�d �e�j�f�d�������YZ�d�e�f�d �������YZ�d�e�j�f�d�������YZ�d�e�f�d�������YZ�d�S(���s���Base option parser setupi����(���t���absolute_importN(���t ���strtobool(���t���string_types(���t���configparser(���t���legacy_config_filet���config_basenamet���running_under_virtualenvt���site_config_files(���t���appdirst���get_terminal_sizes���^PIP_t���PrettyHelpFormatterc�����������B@��s\���e��Z�d��Z�d����Z�d����Z�d�d�d���Z�d����Z�d����Z�d����Z�d ����Z �d ����Z �RS(���s4���A prettier/less verbose help formatter for optparse.c���������O@��sC���d�|�d�<d�|�d�<t�����d�d�|�d�<t�j�j�|��|�|���d��S(���Ni���t���max_help_positioni���t���indent_incrementi����i���t���width(���R ���t���optparset���IndentedHelpFormattert���__init__(���t���selft���argst���kwargs(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyR������s���� c���������C@��s���|��j��|�d�d���S(���Ns��� <%s>s���, (���t���_format_option_strings(���R���t���option(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���format_option_strings!���s����s��� <%s>s���, c���������C@��s����g��}�|�j��r&�|�j�|�j��d���n��|�j�rF�|�j�|�j�d���n��t�|���d�k�rk�|�j�d�|���n��|�j����r��|�j�p��|�j�j����}�|�j�|�|�j������n��d�j �|���S(���s�� Return a comma-separated list of option strings and metavars. :param option: tuple of (short opt, long opt), e.g: ('-f', '--format') :param mvarfmt: metavar format string - evaluated as mvarfmt % metavar :param optsep: separator i����i���t����( ���t���_short_optst���appendt ���_long_optst���lent���insertt���takes_valuet���metavart���destt���lowert���join(���R���R���t���mvarfmtt���optsept���optsR���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyR���$���s���� c���������C@��s���|�d�k�r�d�S|�d�S(���Nt���OptionsR���s���: (����(���R���t���heading(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���format_heading;���s����c���������C@��s#���d�|��j��t�j�|���d���}�|�S(���sz��� Ensure there is only one newline between usage and the first heading if there is no description. s��� Usage: %s s��� (���t���indent_linest���textwrapt���dedent(���R���t���usaget���msg(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���format_usage@���s����c���������C@��sy���|�rq�t��|��j�d���r!�d�}�n�d�}�|�j�d���}�|�j����}�|��j�t�j�|���d���}�d�|�|�f�}�|�Sd�Sd��S(���Nt���maint���Commandst���Descriptions��� s��� s���%s: %s R���(���t���hasattrt���parsert���lstript���rstripR(���R)���R*���(���R���t���descriptiont���label(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���format_descriptionH���s���� c���������C@��s���|�r �|�Sd�Sd��S(���NR���(����(���R���t���epilog(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt ���format_epilogZ���s����c���������C@��s3���g��|�j��d���D]�}�|�|�^�q�}�d�j�|���S(���Ns��� (���t���splitR!���(���R���t���textt���indentt���linet ���new_lines(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyR(���a���s����&(���t���__name__t ���__module__t���__doc__R���R���R���R'���R-���R7���R9���R(���(����(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyR ������s��� t���UpdatingDefaultsHelpFormatterc�����������B@��s���e��Z�d��Z�d����Z�RS(���s����Custom help formatter for use in ConfigOptionParser. This is updates the defaults before expanding them, allowing them to show up correctly in the help listing. c���������C@��s;���|��j��d��k �r(�|��j��j�|��j��j���n��t�j�j�|��|���S(���N(���R2���t���Nonet���_update_defaultst���defaultsR���R���t���expand_default(���R���R���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRF���m���s����(���R?���R@���RA���RF���(����(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRB���f���s���t���CustomOptionParserc�����������B@��s ���e��Z�d�����Z�e�d������Z�RS(���c���������O@��s6���|��j��|�|����}�|��j�j����|��j�j�|�|���|�S(���s*���Insert an OptionGroup at a given position.(���t���add_option_groupt ���option_groupst���popR���(���R���t���idxR���R���t���group(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���insert_option_groupu���s���� c���������C@��s2���|��j��}�x!�|��j�D]�}�|�j�|�j����q�W|�S(���s<���Get a list of all options, including those in option groups.(���t���option_listRI���t���extend(���R���t���rest���i(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���option_list_all~���s���� (���R?���R@���RM���t���propertyRR���(����(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRG���s���s��� t���ConfigOptionParserc�����������B@��se���e��Z�d��Z�e�Z�d����Z�d����Z�d����Z�d����Z�d����Z �d����Z �d����Z�d����Z�d ����Z �RS( ���ss���Custom option parser which updates its defaults by checking the configuration files and environmental variablesc���������O@��s~���t��j����|��_�|�j�d���|��_�|�j�d�t���|��_�|��j����|��_�|��j�rd�|��j�j �|��j���n��t �j�j�|��|�|���d��S(���Nt���namet���isolated( ���R���t���RawConfigParsert���configRJ���RU���t���FalseRV���t���get_config_filest���filest���readR���t���OptionParserR���(���R���R���R���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyR�������s���� c���������C@��s����t��j�j�d�t���}�|�t��j�k�r(�g��St�t���}�|��j�s��|�re�t��j�j �|���re�|�j �|���q��|�j �t���|�j �t��j�j�t �j�d���t�����n��t����r��t��j�j�t�j�t���}�t��j�j �|���r��|�j �|���q��n��|�S(���Nt���PIP_CONFIG_FILEt���pip(���t���ost���environt���getRY���t���devnullt���listR���RV���t���patht���existsR���R���R!���R���t���user_config_dirR���R���t���syst���prefix(���R���t���config_fileR[���t���venv_config_file(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRZ�������s&���� c���������C@��sG���y�|�j��|�|���SWn,�t�j�k �rB�}�d�|�GHt�j�d���n�Xd��S(���Ns*���An error occurred during configuration: %si���(���t���check_valueR���t���OptionValueErrorRh���t���exit(���R���R���t���keyt���valt���exc(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt ���check_default����s ���� c���������C@��s��i��}�x6�d�|��j��f�D]%�}�|�j�|��j�|��j�|�������q�W|��j�sg�|�j�|��j�|��j��������n��t�j�|��j���|��_ �t ����}�xG|�j����D]9\�}�}�|�s��q��n��|��j�|���}�|�d�k�r��q��n��|�j�d�k�r��t�|���}�n��|�j�d�k�r/|�j����}�g��|�D]�}�|��j�|�|�|���^�q}�n��|�j�d�k�r�|�j�|�j���|�j����} �|�j�| �|���}�|�j�pxd �} �|�j�p�i��}�|�j�|�| �|�|��| �|���n�|��j�|�|�|���}�|�|�|�j�<q��Wx$�|�D]�}�t�|��j �|���|�|�<q�Wd�|��_ �|�S( ���s����Updates the given defaults with values from the config files and the environ. Does a little special handling for certain types of options (lists).t���globalt ���store_truet���store_falset���countR���t���callbackN(���Rt���Ru���Rv���(����(���RU���t���updatet���normalize_keyst���get_config_sectionRV���t���get_environ_varsR���t���ValuesRE���t���valuest���sett���itemst ���get_optionRC���t���actionR���R:���Rr���t���addR���t���get_opt_stringt ���convert_valuet ���callback_argst���callback_kwargsRw���t���getattr(���R���RE���RX���t���sectiont ���late_evalRo���Rp���R���t���vt���opt_strR���R���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRD�������s@���� + c���������C@��sY���i��}�xL�|�D]D�\�}�}�|�j��d�d���}�|�j�d���sG�d�|�}�n��|�|�|�<q �W|�S(���s����Return a config dictionary with normalized keys regardless of whether the keys were specified in environment variables or in config filest���_t���-s���--s���--%s(���t���replacet ���startswith(���R���R���t ���normalizedRo���Rp���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRy�������s���� c���������C@��s&���|��j��j�|���r"�|��j��j�|���Sg��S(���s ���Get a section of a configuration(���RX���t���has_sectionR���(���R���RU���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRz�����s����c���������c@��sS���xL�t��j�j����D];�\�}�}�t�j�|���r�t�j�d�|���j����|�f�Vq�q�Wd�S(���s@���Returns a generator with all environmental vars with prefix PIP_R���N(���R`���Ra���R���t���_environ_prefix_ret���searcht���subR ���(���R���Ro���Rp���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyR{�����s����c���������C@��s����|��j��s�t�j�|��j���S|��j�|��j�j������}�x]�|��j����D]O�}�|�j�|�j���}�t �|�t ���r>�|�j����}�|�j�|�|���|�|�j�<q>�q>�Wt�j�|���S(���s����Overriding to make updating the defaults after instantiation of the option parser possible, _update_defaults() does the dirty work.( ���t���process_default_valuesR���R|���RE���RD���t���copyt���_get_all_optionsRb���R���t ���isinstanceR���R����Rl���(���R���RE���R���t���defaultR����(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���get_default_values��s���� c���������C@��s(���|��j��t�j���|��j�d�d�|���d��S(���Ni���s���%s (���t���print_usageRh���t���stderrRn���(���R���R,���(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���error#��s����(���R?���R@���RA���RY���RV���R���RZ���Rr���RD���Ry���Rz���R{���R����R����(����(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyRT�������s��� ( 5 (���RA���t ���__future__R����Rh���R���R`���t���reR)���t���distutils.utilR���t���pip._vendor.sixR���t���pip._vendor.six.movesR���t ���pip.locationsR���R���R���R���t ���pip.utilsR���R ���t���compilet���IR����R���R ���RB���R]���RG���RT���(����(����(����s2���/usr/lib/python2.7/site-packages/pip/baseparser.pyt���<module>���s ���"O