Your IP : 3.144.237.52
3
�PfqG � @ s( d dl mZ d dlZd dlZd dlZd dlZd dlZd dlZd dlZd dlm Z yd dl
Z
W n ek
rt dZ
Y nX d dlm
Z
d dlmZ d dlmZmZ d dlmZmZmZ d dlmZ d d lmZmZ d d
lmZ d dlmZ d dl m!Z! d d
l"m#Z#m$Z$ ej%e&�Z'G dd� de�Z(dd� Z)dS )� )�absolute_importN)�path)�RequirementSet)�RequirementCommand)�virtualenv_no_global�distutils_scheme)�InstallationError�CommandError�PreviousBuildDirError)�
cmdoptions)�
ensure_dir�get_installed_version)�BuildDirectory)�RemovedInPip10Warning)�check_path_owner)�
WheelCache�WheelBuilderc s4 e Zd ZdZdZdZdZ� fdd�Zdd� Z� Z S ) �InstallCommandaI
Install packages from:
- PyPI (and other indexes) using requirement specifiers.
- VCS project urls.
- Local project directories.
- Local or remote source archives.
pip also supports installing from "requirements files", which provide
an easy way to specify a whole environment to be installed.
�installa%
%prog [options] <requirement specifier> [package-index-options] ...
%prog [options] -r <requirements file> [package-index-options] ...
%prog [options] [-e] <vcs project url> ...
%prog [options] [-e] <local project path> ...
%prog [options] <archive url/path> ...zInstall packages.c
s0 t t| �j||� | j}|jtj� � |jtj� � |jtj� � |jtj � � |jddddd dd� |jddd d
ddd dd� |jtj
� � |jd
ddddd� |jdddddgdd� |jddddd� |jdddddd� |jtj� � |jtj� � |jtj
� � |jtj� � |jd d!dd"d� |jd#d$dd%d� |jd&d'dd d(d� |jd)d*d+d d,d� |jd-d.dd d/d� |jd0dd1d2d3d4� |jd5d6d1d7d8� |jtj� � |jtj� � |jtj� � |jtj� � |jtj� � |jtj� � |jtj� � tjtj| j�}| jjd9|� | jjd9|� d S ):Nz-tz--target�
target_dir�dirz�Install packages into <dir>. By default this will not replace existing files/folders in <dir>. Use --upgrade to replace existing packages in <dir> with new versions.)�dest�metavar�default�helpz-dz
--downloadz--download-dirz--download-directory�download_dirz`Download packages into <dir> instead of installing them, regardless of what's already installed.z-Uz --upgrade�upgrade�
store_truez�Upgrade all specified packages to the newest available version. The handling of dependencies depends on the upgrade-strategy used.)r �actionr z--upgrade-strategy�upgrade_strategyZeagerzonly-if-neededa3 Determines how dependency upgrading should be handled. "eager" - dependencies are upgraded regardless of whether the currently installed version satisfies the requirements of the upgraded package(s). "only-if-needed" - are upgraded only when they do not satisfy the requirements of the upgraded package(s).)r r �choicesr z--force-reinstall�force_reinstallzKWhen upgrading, reinstall all packages even if they are already up-to-date.z-Iz--ignore-installed�ignore_installedz5Ignore the installed packages (reinstalling instead).z--user�
use_user_sitez�Install to the Python user install directory for your platform. Typically ~/.local/, or %APPDATA%\Python on Windows. (See the Python documentation for site.USER_BASE for full details.)z--egg�as_eggz�Install packages as eggs, not 'flat', like pip normally does. This option is not about installing *from* eggs. (WARNING: Because this option overrides pip's normal install logic, requirements files may not behave as expected.)z--root� root_pathz=Install everything relative to this alternate root directory.z--strip-file-prefix�strip_file_prefix�prefixz5Strip given prefix from script paths in wheel RECORD.z--prefix�prefix_pathzIInstallation prefix where lib, bin and other top-level folders are placedz --compile�compileTzCompile py files to pyc)r r r r z--no-compileZstore_falsezDo not compile py files to pyc)r r r r )�superr �__init__�cmd_optsZ
add_optionr ZconstraintsZeditableZrequirements� build_dir�src�ignore_requires_pythonZno_deps�install_options�global_optionsZ use_wheelZno_use_wheelZ no_binaryZonly_binaryZpre�no_clean�require_hashesZmake_option_groupZindex_group�parserZinsert_option_group)�self�args�kwr, Z
index_opts)� __class__� �/usr/lib/python3.6/install.pyr+ 8 s� zInstallCommand.__init__c &