ó 9ÕÒTc@@s+ddlmZddlZddlZddlZddlZddlZddlZddlm Z m Z m Z ddl m Z mZmZddlmZddlmZddlmZmZmZddlmZdd lmZdd lmZmZeje ƒZ!d efd „ƒYZ"dS( i(tabsolute_importN(tInstallRequirementtRequirementSettparse_requirements(t build_prefixtvirtualenv_no_globaltdistutils_scheme(tCommand(t PackageFinder(tInstallationErrort CommandErrortPreviousBuildDirError(t cmdoptions(tBuildDirectory(tRemovedInPip7WarningtRemovedInPip8WarningtInstallCommandcB@s;eZdZdZdZdZd„Zd„Zd„ZRS(sI 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. tinstalls% %prog [options] [package-index-options] ... %prog [options] -r [package-index-options] ... %prog [options] [-e] ... %prog [options] [-e] ... %prog [options] ...sInstall packages.c O@stt|ƒj||Ž|j}|jtjjƒƒ|jtjjƒƒ|jtj jƒƒ|jdddddddddd ƒ|jd d d d ddddddddƒ|jtj jƒƒ|jtj jƒƒ|jddddddddƒ|jdddddddƒ|jddddddddƒ|jtj jƒƒ|jdddddddƒ|jd dd!dddd"ƒ|jtjjƒƒ|jtjjƒƒ|jd#dd$dddd%ƒ|jd&dd'dddd(ƒ|jd)dd*dddddd+ƒ|jd,dddd-dtdd.ƒ|jd/dd0dd-dd1ƒ|jtjjƒƒ|jtjjƒƒ|jd2dddtdd3ƒ|jtjjƒƒtjtj|jƒ}|jjd4|ƒ|jjd4|ƒdS(5Ns-ts--targettdestt target_dirtmetavartdirtdefaultthelps¥Install packages into . By default this will not replace existing files/folders in . Use --upgrade to replace existing packages in with new versions.s-ds --downloads--download-dirs--download-directoryt download_dirs`Download packages into instead of installing them, regardless of what's already installed.s-Us --upgradetupgradetactiont store_trues’Upgrade all specified packages to the newest available version. This process is recursive regardless of whether a dependency is already satisfied.s--force-reinstalltforce_reinstallsKWhen upgrading, reinstall all packages even if they are already up-to-date.s-Is--ignore-installedtignore_installeds5Ignore the installed packages (reinstalling instead).s --no-installt no_installsNDEPRECATED. Download and unpack all packages, but don't actually install them.s --no-downloadt no_downloadsDEPRECATED. Don't download any packages, just install the ones already downloaded (completes an install run with --no-install).s--usert use_user_sitesInstall using the user scheme.s--eggtas_eggsâ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.)s--roott root_paths=Install everything relative to this alternate root directory.s --compiletcompilesCompile py files to pycs --no-compilet store_falsesDo not compile py files to pycs--presYInclude pre-release and development versions. By default, pip only finds stable versions.i(tsuperRt__init__tcmd_optst add_optionR teditabletmaket requirementst build_dirtNonetdownload_cachetsrctno_depstinstall_optionstglobal_optionstTruet use_wheelt no_use_wheeltFalsetno_cleantmake_option_groupt index_grouptparsertinsert_option_group(tselftargstkwR't index_opts((s:/usr/lib/python2.7/vendor-packages/pip/commands/install.pyR&0s®     cC@s[td|jd|d|jd|jd|jd|jd|jd|jd |jd |ƒ S( s¨ Create a package finder appropriate to this install command. This method is meant to be overridden by subclasses, not called directly. t find_linkst index_urlsR4tallow_externaltallow_unverifiedtallow_all_externalt trusted_hoststallow_all_prereleasestprocess_dependency_linkstsession( RR@R4RBRCRDREtpreRG(R<toptionsRARH((s:/usr/lib/python2.7/vendor-packages/pip/commands/install.pyt_build_package_finderµs        c#C@sâ|js|jr%tjdtƒn|jdkrR|jsF|jrRt|_n|jrpt |_t |_ n|jr”t j j |jƒ|_nt j j |jƒ|_|jp¸g}|jrìtƒrÜtdƒ‚n|jdƒnd}|jrvt |_ tjƒ}t j j |jƒ|_t j j|jƒrbt j j|jƒ rbtdƒ‚n|jd|ƒn|jp‚g}|jg|j}|jrÃtjddj |ƒƒg}n|j!rßtjdtƒn|j"rtjd tƒ||j"7}n|j#r$tjd t$ƒn|j%|ƒv}|j&|||ƒ}|j'pZ|j } t(|jd | ƒ0} t)d | d |jd|jd|j*d|j+d|j d|j,d|j-d|jd|d|d|j.d|j/ƒ } x0|D](} | j0t1j2| dd|j/ƒƒqòWx9|j3D].} | j0t1j4| d|j5d|j/ƒƒq(WxG|j6D]<} x3t7| d|d|d|ƒD]}| j0|ƒq‰WqdW| j8si|j9d6}|j:rëdt;|ddj |j:ƒƒ}n d |}tj<|ƒdSzkyG|js%| j=|ƒn | j>ƒ|js| j?||d!|j@ƒtA| jBd"tCjDdƒƒ}g}xk|D]c}|j9}y3tE|d#ƒr½|jFr½|d$|jF7}q½nWntGk rÑnX|j|ƒq|Wdj |ƒ}|rOtjd%|ƒqOnAdj g| jHD]}|j9^qƒ}|rOtjd&|ƒnWntIk rot |_'‚nXWd|j' rž|j s‘|jrž| jJƒnXWdQXWdQX|jrÞt j j|jƒsÜt jK|jƒntLd'd(|ƒd)}xÙt jM|ƒD]È}t j j |j|ƒ}t j j|ƒr«|j*sQtj<d*|ƒqnt j jN|ƒrytj<d+|ƒqnt j j|ƒr›tOjP|ƒq«t jQ|ƒntOjRt j j ||ƒ|ƒqWtOjP|ƒn| S(,NsZ--no-install and --no-download are deprecated. See https://github.com/pypa/pip/issues/906.sZCan not perform a '--user' install. User site-packages are not visible in this virtualenv.s--users=Target path exists but is not a directory, will not continue.s--home=sIgnoring indexes: %st,sˆ--use-mirrors has been deprecated and will be removed in the future. Explicit uses of --index-url and/or --extra-index-url is suggested.s„--mirrors has been deprecated and will be removed in the future. Explicit uses of --index-url and/or --extra-index-url is suggested.s|--download-cache has been deprecated and will be removed in the future. Pip now automatically uses and configures its cache.tdeleteR,tsrc_dirRRR!Rtignore_dependenciesRR RRHt pycompiletisolatedt default_vcstfinderRJtnames^You must give at least one requirement to %(name)s (maybe you meant "pip %(name)s %(links)s"?)tlinkst sLYou must give at least one requirement to %(name)s (see "pip help %(name)s")troottkeytinstalled_versiont-sSuccessfully installed %ssSuccessfully downloaded %stthometpurelibsKTarget directory %s already exists. Specify --upgrade to force replacement.s„Target directory %s already exists and is a link. Pip will not automatically replace links, please remove if replacement is desired.(SRRtwarningstwarnRR,R-RRR3RtostpathtabspathRNR1R RR tappendRttempfiletmkdtemptexiststisdirR R2t index_urltextra_index_urlstno_indextloggertinfotjoint use_mirrorstmirrorsR.Rt_build_sessionRKR7R RRR!RORR#t isolated_modetadd_requirementRt from_linet editablest from_editableRRR+Rthas_requirementsRTR@tdicttwarningt prepare_filest locate_filesRR"tsortedtsuccessfully_installedtoperatort attrgetterthasattrRYt Exceptiontsuccessfully_downloadedR t cleanup_filestmakedirsRtlistdirtislinktshutiltrmtreetremovetmove(R<RJR=R1ttemp_target_dirR2RARHRSt build_deleteR,trequirement_setRTtfilenametreqtoptstmsgtreqstitemstitemt installedt downloadedtlib_dirttarget_item_dir((s:/usr/lib/python2.7/vendor-packages/pip/commands/install.pytrunÈs6                                      "                   ( t__name__t __module__t__doc__RTtusagetsummaryR&RKR˜(((s:/usr/lib/python2.7/vendor-packages/pip/commands/install.pyRs  … (#t __future__RtloggingR}R`RdR†R^tpip.reqRRRt pip.locationsRRRtpip.basecommandRt pip.indexRtpip.exceptionsR R R tpipR tpip.utils.buildR tpip.utils.deprecationRRt getLoggerR™RkR(((s:/usr/lib/python2.7/vendor-packages/pip/commands/install.pyts