<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"
        integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD" crossorigin="anonymous">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.3.0/css/all.min.css"
        integrity="sha512-SzlrxWUlpfuzQ+pcUCosxcglQRNAq/DZjVsC0lE40xsADsfeQoEypE+enwcOiGjk/bSuGGKHEyjSoQ1zVisanQ=="
        crossorigin="anonymous" referrerpolicy="no-referrer" />
</head>
</html>
B
    š•Re6  ã               @   sÂ   d dl mZ d dlZd dlZd dlmZ d dlmZ d dlm	Z	m
Z
 d dlmZ d dlmZ d dlmZmZmZ d d	lmZ d d
lmZ er¤d dlmZ d dlmZ e e¡ZG dd„ de	ƒZdS )é    )Úabsolute_importN)Ú
cmdoptions)Úmake_target_python)ÚRequirementCommandÚwith_cleanup)ÚSUCCESS)Úget_requirement_tracker)Ú
ensure_dirÚnormalize_pathÚwrite_output)ÚTempDirectory)ÚMYPY_CHECK_RUNNING)ÚValues)ÚListc               @   s(   e Zd ZdZdZdd„ Zedd„ ƒZdS )ÚDownloadCommandaL  
    Download packages from:

    - PyPI (and other indexes) using requirement specifiers.
    - VCS project urls.
    - Local project directories.
    - Local or remote source archives.

    pip also supports downloading from "requirements files", which provide
    an easy way to specify a whole environment to be downloaded.
    a  
      %prog [options] <requirement specifier> [package-index-options] ...
      %prog [options] -r <requirements file> [package-index-options] ...
      %prog [options] <vcs project url> ...
      %prog [options] <local project path> ...
      %prog [options] <archive url/path> ...c          
   C   sL  | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t 	¡ ¡ | j  t 
¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j  t ¡ ¡ | j jddddddtjdd t | j ¡ t tj| j¡}| j d	|¡ | j d	| j ¡ d S )
Nz-dz--destz--destination-dirz--destination-directoryÚdownload_dirÚdirzDownload packages into <dir>.)ÚdestÚmetavarÚdefaultÚhelpr   )Úcmd_optsÚ
add_optionr   ÚconstraintsÚrequirementsÚ	build_dirÚno_depsÚglobal_optionsÚ	no_binaryÚonly_binaryÚprefer_binaryÚsrcÚpreÚrequire_hashesÚprogress_barÚno_build_isolationÚ
use_pep517Úno_use_pep517ÚosÚcurdirÚadd_target_python_optionsÚmake_option_groupÚindex_groupÚparserÚinsert_option_group)ÚselfÚ
index_opts© r1   úŽ/builddir/build/BUILDROOT/alt-python37-pip-20.2.4-6.el8.x86_64/opt/alt/python37/lib/python3.7/site-packages/pip/_internal/commands/download.pyÚadd_options*   s6    zDownloadCommand.add_optionsc          	   C   sü   d|_ g |_t |¡ t|jƒ|_t|jƒ |  |¡}t|ƒ}| j	|||d}|j
pX|j }|  tƒ ¡}t|j|ddd}|  ||||¡}	| j||||||jdd}
| j|
|||jd}|  |¡ |j|	dd}d	 d
d„ |j ¡ D ƒ¡}|røtd|ƒ tS )NT)ÚoptionsÚsessionÚtarget_pythonÚdownload)ÚdeleteÚkindÚglobally_managedF)Útemp_build_dirr4   Úreq_trackerr5   Úfinderr   Úuse_user_site)Úpreparerr=   r4   Úpy_version_info)Úcheck_supported_wheelsú c             S   s   g | ]}|j r|j‘qS r1   )Úsuccessfully_downloadedÚname)Ú.0Úreqr1   r1   r2   ú
<listcomp>‰   s   z'DownloadCommand.run.<locals>.<listcomp>zSuccessfully downloaded %s)Úignore_installedÚ	editablesr   Úcheck_dist_restrictionr
   r   r	   Úget_default_sessionr   Ú_build_package_finderÚno_cleanr   Úenter_contextr   r   Úget_requirementsÚmake_requirement_preparerÚmake_resolverÚpython_versionÚtrace_basic_infoÚresolveÚjoinr   Úvaluesr   r   )r/   r4   Úargsr5   r6   r=   Úbuild_deleter<   Ú	directoryÚreqsr?   ÚresolverÚrequirement_setÚ
downloadedr1   r1   r2   ÚrunN   sP    







zDownloadCommand.runN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__Úusager3   r   r^   r1   r1   r1   r2   r      s   $r   )Ú
__future__r   Úloggingr(   Zpip._internal.clir   Zpip._internal.cli.cmdoptionsr   Úpip._internal.cli.req_commandr   r   Úpip._internal.cli.status_codesr   Úpip._internal.req.req_trackerr   Úpip._internal.utils.miscr	   r
   r   Úpip._internal.utils.temp_dirr   Úpip._internal.utils.typingr   Úoptparser   Útypingr   Ú	getLoggerr_   Úloggerr   r1   r1   r1   r2   Ú<module>   s   
