OwlCyberSecurity - MANAGER
Edit File: cmdoptions.cpython-38.pyc
U �� g�m � @ s� d Z ddlmZ ddlZddlZddlZddlZddlmZ ddl m Z ddlmZm Z mZ ddlmZ ddlmZ dd lmZmZ dd lmZ ddlmZ ddlmZ dd lmZ ddlmZ ddlm Z e�r ddl!m"Z"m#Z#m$Z$m%Z%m&Z& ddlm'Z'm(Z( ddl)m*Z* e�+e,�Z-dd� Z.dd� Z/d�dd�Z0d�dd�Z1dd� Z2G dd� de �Z3e e d d!d"d"d#d$�Z4e e d%d&d'dd(d)�Z5e e d*d+d,d'ded)�Z6e e d-d.d/d0dd1d)�Z7e e d2d3d'dd4d)�Z8e e d5d6d7d'd8d$�Z9e e d9d:d;d0dd<d)�Z:e e d=d>d?e;e �<� �d@dAdB�=e �<� � dC dD�Z>e e3dEdFdGdHdIdIdJdK�Z?e e dLdMd'ded)�Z@e e dNdOdPdQdRdS�ZAe e dTdUdVdWdXdS�ZBe e dYdZd[d\d]d^d_d`�ZCe e dadbdPdQedS�ZDdcdd� ZEe e3dedfdIdIdgdh�ZFe e3didjdIddIdkdl�ZGe e dmdndodpdqejHdrds�ZIdtdu� ZJe e dvdwd'ddxd)�ZKdydz� ZLd{d|� ZMd}d~� ZNdd�� ZOd�d�� ZPd�d�� ZQe e3d�d�d�d�d�dId�e� d�eQd�d��ZRd�d�� ZSd�d�� ZTd�d�� ZUd�d�� ZVd�d�� ZWe e d�d�d�dd�ds�ZXd�d�� ZYd�d�� ZZe e d�d�d�d�eZdPded��d�� Z[e e d�d�d�dd�ds�Z\e e d�d�d�dd�ds�Z]d�d�� Z^d�d�� Z_d�d�� Z`e e3d�d�ed�dId�d��Zad�d�� Zbe e d�d�d�ebd�d��Zce e d�d�d�d'dd�d)�Zdd�d�� Zee e3d�d�d�d�d�dId�d�eed�dčZfe e d�d�d'd�d$�Zge e d�d�d�d�d�d)�Zhd�d΄ Zie e d�d�d'dd�d)�Zje e d�d�d�eidedӍZke e d�d�d�d�d�dٍZle e d�d�d�d�d�dٍZme e d�d'dd�dߍZne e d�d'dd�dߍZoe e d�d�d'd�d�d)�Zpe e d�d�d�d'ed$�Zqd�d� Zre e d�d�d�erd�d�d�Zse e d�d�d'dd�d)�Zte e3d�dIdId�d�d�Zud�d�� Zve e d�d�d'dd�d)�Zwd�e4e5e6e7e9e:e?e@eAeBeCeDeEeMeFeGeaecepe8ewgd��Zxd�eIeJeKeLgd��ZydS )�aC shared options and groups The principle here is to define options once, but *not* instantiate them globally. One reason being that options with action='append' can carry state between parses. pip parses general options twice internally, and shouldn't pass on state. To be consistent, all options will follow this design. � )�absolute_importN)� strtobool)�partial)� SUPPRESS_HELP�Option�OptionGroup)�dedent)�CommandError)�USER_CACHE_DIR�get_src_prefix)� FormatControl)�PyPI)�TargetPython)� STRONG_HASHES)�MYPY_CHECK_RUNNING)� BAR_TYPES)�Any�Callable�Dict�Optional�Tuple)�OptionParser�Values)�ConfigOptionParserc C s. d� ||�}t�d�|�� ��}| �|� dS )z� Raise an option parsing error using parser.error(). Args: parser: an OptionParser instance. option: an Option instance. msg: the error text. z{} error: {}� N)�format�textwrapZfill�join�split�error)�parser�option�msg� r# �>/usr/lib/python3/dist-packages/pip/_internal/cli/cmdoptions.py�raise_option_error) s r% c C s, t || d �}| d D ]}|�|� � q|S )z� Return an OptionGroup object group -- assumed to be dict with 'name' and 'options' keys parser -- an optparse Parser �name�options)r � add_option)�groupr Zoption_groupr! r# r# r$ �make_option_group8 s r* c sP � dkr| � � fdd�}dddg}t t||��rL| j}|�� tjddd � dS ) z�Disable wheels if per-setup.py call options are set. :param options: The OptionParser options to update. :param check_options: The options to check, if not supplied defaults to options. Nc s t � | d �S �N)�getattr)�n�� check_optionsr# r$ �getnameP s z+check_install_build_global.<locals>.getnameZ build_options�global_options�install_optionszbDisabling all use of wheels due to the use of --build-option / --global-option / --install-option.� )� stacklevel)�any�map�format_controlZdisallow_binaries�warnings�warn)r'