[ Avaa Bypassed ]




Upload:

Command:

hmhc3928@3.145.88.104: ~ $


�V�Y�@s�dZddlmZddlmZddlmZddlZddl	Z	ddl
Z
ddlZddlZddl
Z
ddlmZddlmZddlmZddlmZdd	lmZdd
lmZddlmZddlmZdd
lmZddlZddlmZddlmZdSZdTZdd�Zdd�Zdd�Zdd�Z dddd�Z!ddd �Z"Gd!d"�d"ej�Z#Gd#d$�d$ej�Z$Gd%d&�d&ej%�Z&Gd'd(�d(e
j'�Z(d)d*�Z)y3dd+l*m+Z+Gd,d-�d-e+j,�Z-d.Z.Wne/k
rTdZ.YnXd/d0�Z0d1Z1d2Z2d3e2d4e2d5e1iZ3e	j4j5ej6�dd6d7�Z7Gd8d9�d9ej�Z8Gd:d;�d;ej�Z9Gd<d=�d=ej:�Z;Gd>d?�d?ej�Z<d@dA�Z=GdBdC�dCej�Z>y,ddDlm?Z?d.Z@e?jAZAe?jBZBWn$e/k
r�dZ@dZAdZBYnXdEdF�ZCdGdH�ZDdIdJ�ZEdKdL�ZFddMdN�ZGdOdP�ZHddQdR�ZIejJjKZKdS)Uz4
Utilities with minimum-depends for use in setup.py
�)�unicode_literals)�install)�logN)�develop)�easy_install)�egg_info)�install_scripts)�sdist)�extra_files)�git)�options)�
testr_command)�version�requirements.txt�tools/pip-requires�test-requirements.txt�tools/test-requirescCsxtjjd�}|r8tdd�|jd�D��Sttdttj	d�j
ttjjt
���tt
�S)NZPBR_REQUIREMENTS_FILEScss|]}|j�VqdS)N)�strip)�.0�f�r�
/packaging.py�	<genexpr>5sz)get_requirements_files.<locals>.<genexpr>�,z-pyr)�os�environ�get�tuple�split�list�map�str�sys�version_info�join�path�splitext�REQUIREMENTS_FILES)�filesrrr�get_requirements_files2s r)cCsOg}|j|d�}|r+|j|�|j|�dj|�||<dS)z5Append a 
 separated list to possibly existing value.��
N)r�append�extendr$)�config�keyZ	text_listZ	new_valueZ
current_valuerrr�append_text_list?s

r0cCsdd�|D�S)NcSs(g|]}tjj|�r|�qSr)rr%�exists)rrrrr�
<listcomp>Js	z!_any_existing.<locals>.<listcomp>r)Z	file_listrrr�
_any_existingIsr3c
CsGx@t|�D]2}t|d��}|j�jd�SWdQRXq
WgS)N�rr+)r3�open�readr)�requirements_filesZrequirements_fileZfilrrr�get_reqs_from_filesNsr8Fc	
Cs�|dkrt�}dd�}g}x�t|�D]�}|j�s4|jd�rYq4|jd�r�|jd�d}|t|gd|�7}q4ytjj|�j	}Wnt
k
r�d}YnXtjd|�r�tj
d	||�}nHtjd
|�rtj
d||�}ntjd|�r=d}d
}|dk	r�tj
dd|�}|r�|jd�}|dkr�d}|d|�}|j|�q4tjd||f�q4W|S)NcSstjdd|jd��S)Nz([\w.]+)-([\w.-]+)z\1>=\2�)�re�sub�group)�matchrrr�egg_fragmentZs	z(parse_requirements.<locals>.egg_fragment�#z-r� ��
strip_markersz\s*-e\s+z\s*-e\s+.*#egg=(.*)$z
\s*https?:z\s*https?:.*#egg=(.*)$z\s*-f\s+zIndex Locationz#.*$r*�;rz[pbr] Excluding %s: %s)r)r8r�
startswith�	partition�parse_requirements�
pkg_resourcesZRequirement�parse�project_name�
ValueErrorr:r=r;�findr,r�info)	r7rBr>Zrequirements�lineZreq_filerI�reasonZsemi_posrrrrFUsD	
rFcCs�|dkrt�}g}xyt|�D]k}tjd|�rCq(tjd|�rt|jtjdd|��q(tjd|�r(|j|�q(W|S)Nz
(\s*#)|(\s*$)z\s*-[ef]\s+r*z
\s*https?:)r)r8r:r=r,r;)r7Zdependency_linksrMrrr�parse_dependency_links�s	rOc@s(eZdZdZdZdd�ZdS)�InstallWithGitz�Extracts ChangeLog and AUTHORS from git then installs.

    This is useful for e.g. readthedocs where the package is
    installed and then docs built.
    rcCst|j�tjj|�S)N)�	_from_git�distributionr�run)�selfrrrrS�s
zInstallWithGit.runN)�__name__�
__module__�__qualname__�__doc__�command_namerSrrrrrP�srPc@s(eZdZdZdZdd�ZdS)�LocalInstallz�Runs python setup.py install in a sensible manner.

    Force a non-egg installed in the manner of
    single-version-externally-managed, which allows us to install manpages
    and config files.
    rcCst|j�tjj|�S)N)rQrR�
du_installrrS)rTrrrrS�s
zLocalInstall.runN)rUrVrWrXrYrSrrrrrZ�srZc@s(eZdZdZdZdd�ZdS)�	TestrTestz&Make setup.py test do the right thing.�testcCstjj|�dS)N)r
�TestrrS)rTrrrrS�sz
TestrTest.runN)rUrVrWrXrYrSrrrrr\�sr\c@sLeZdZdZeZgZdZdd�Zdd�Zdd�Z	d	S)
�LocalRPMVersionz:Output the rpm *compatible* version string of this packageZrpm_versioncCs?tjd�|jj�}ttj|�j�j��dS)Nz[pbr] Extracting rpm version)	rrLrR�get_name�printrZVersionInfoZsemantic_versionZ
rpm_string)rT�namerrrrS�s
zLocalRPMVersion.runcCsdS)Nr)rTrrr�initialize_options�sz"LocalRPMVersion.initialize_optionscCsdS)Nr)rTrrr�finalize_options�sz LocalRPMVersion.finalize_optionsN)
rUrVrWrX�descriptionZuser_optionsrYrSrcrdrrrrr_�sr_cCstjS)N)r
�
have_testrrrrrrf�srf)�commandsc@s(eZdZdZdZdd�ZdS)�NoseTestz)Fallback test runner if testr is a no-go.r]cCstjj|�dS)N)rg�	nosetestsrS)rTrrrrS�szNoseTest.runN)rUrVrWrXrYrSrrrrrh�srhTcCstS)N)�
_have_noserrrr�	have_nose�srka5#PBR Generated from %(group)r

import threading

from %(module_name)s import %(import_target)s

if __name__ == "__main__":
    import argparse
    import socket
    import wsgiref.simple_server as wss

    my_ip = socket.gethostbyname(socket.gethostname())
    parser = argparse.ArgumentParser(
        description=%(import_target)s.__doc__,
        formatter_class=argparse.ArgumentDefaultsHelpFormatter)
    parser.add_argument('--port', '-p', type=int, default=8000,
                        help='TCP port to listen on')
    args = parser.parse_args()
    server = wss.make_server('', args.port, %(invoke_target)s())

    print("*" * 80)
    print("STARTING test server %(module_name)s.%(invoke_target)s")
    url = "http://%%s:%%d/" %% (my_ip, server.server_port)
    print("Available at %%s" %% url)
    print("DANGER! For testing only, do not use in production")
    print("*" * 80)

    server.serve_forever()
else:
    application = None
    app_lock = threading.Lock()

    with app_lock:
        if application is None:
            application = %(invoke_target)s()

z�# PBR Generated from %(group)r

import sys

from %(module_name)s import %(import_target)s


if __name__ == "__main__":
    sys.exit(%(invoke_target)s())
Zconsole_scriptsZgui_scriptsZwsgi_scriptsc	
cs�tjd||�}x�tj�D]�\}}x�|j|�j�D]�\}}|jsot|j�dkr{td��|td|d|j	d|jddd	j
|j��}|||fVqDWq"Wd
S)z$Override entrypoints console_script.r*rAzBScript targets must be of the form 'func' or 'Class.class_method'.r<�module_nameZ
import_targetrZ
invoke_target�.N)rZget_script_header�ENTRY_POINTS_MAP�itemsZ
get_entry_mapZattrs�lenrJ�dictrlr$)	�dist�
executable�
is_wininst�headerr<�templaterbZepZscript_textrrr�override_get_script_args6s"		
rwc@s"eZdZdZdd�ZdS)�LocalDeveloprcCsStjdkr"tjj||�S|jsOx!t|�D]}|j|�q8WdS)N�win32)r"�platformr�install_wrapper_scriptsZexclude_scriptsrw�write_script)rTrr�argsrrrr{Ls
	z$LocalDevelop.install_wrapper_scriptsN)rUrVrWrYr{rrrrrxHsrxc@s(eZdZdZdZdd�ZdS)�LocalInstallScriptsz(Intercepts console scripts entry_points.rc	Cs.ddl}|jd�|jjr>|jjjj|�n	g|_|jrTdS|j	d�}t
j|jt
j
|j|j�|j|j�}|j	d�}t|dtj�}t|j	d�dd�}tjdkr�t}ntj}d	|}x'||||�D]}|j|�qWdS)
NrrZ
build_scriptsrsZ
bdist_wininstZ_is_runningF�ntz"%s")Z!distutils.command.install_scriptsZrun_commandrR�scripts�commandrrSZoutfilesZno_ep�get_finalized_commandrGZDistributionZegg_baseZPathMetadatarZegg_nameZegg_version�getattrrZsys_executablerrbrw�get_script_argsr|)	rT�	distutils�ei_cmdrrZbs_cmdrsrtr�r}rrrrSXs.
				
zLocalInstallScripts.runN)rUrVrWrXrYrSrrrrr~Tsr~c@s.eZdZdZdd�Zdd�ZdS)�LocalManifestMakerz?Add any files that are in git and some standard sensible files.cCs4x-dddddgD]}|jj|�qWdS)Nzinclude AUTHORSzinclude ChangeLogzexclude .gitignorezexclude .gitreviewzglobal-exclude *.pyc)�filelistZprocess_template_line)rTZ
template_linerrr�_add_pbr_defaultss
z$LocalManifestMaker._add_pbr_defaultscCs�|jjd�}tjj|�|jj|j�|jj|j�|jjt	j
��tj|dd�}|s�t
j�}|r�|jj|�ntjj|j�r�|j�|jd�}|j�|jjdd|j�dS)N�pbrZskip_git_sdistZSKIP_GIT_SDISTr�*�prefix)rR�get_option_dictr	�add_defaultsr�r,rv�manifestr-r
Zget_extra_filesrZget_boolean_optionrZ_find_git_filesrr%r1Z
read_manifestr�r�Zinclude_patternr)rT�option_dictZshould_skipZrcfilesr�rrrr��s 	

zLocalManifestMaker.add_defaultsN)rUrVrWrXr�r�rrrrr�|s
r�c@s(eZdZdZdZdd�ZdS)�LocalEggInfozAOverride the egg_info command to regenerate SOURCES.txt sensibly.rcCs�tjj|jd�}tjj|�sLtjjd�sLdtjkr�tjd�t	|j
�}||_|j�|j
|_
nUtjd�tj�|_
x6t|d�j�jd�D]}|j
j|�q�WdS)	apGenerate SOURCES.txt only if there isn't one already.

        If we are in an sdist command, then we always want to update
        SOURCES.txt. If we are not in an sdist command, then it doesn't
        matter one flip, and is actually destructive.
        However, if we're in a git context, it's always the right thing to do
        to recreate SOURCES.txt
        zSOURCES.txtz.gitr	z[pbr] Processing SOURCES.txtz"[pbr] Reusing existing SOURCES.txtr4r+N)rr%r$rr1r"�argvrrLr�rRr�rSr�ZFileListr5r6rr,)rTZmanifest_filenameZmm�entryrrr�find_sources�s	
	

%zLocalEggInfo.find_sourcesN)rUrVrWrXrYr�rrrrr��sr�cCsZ|jd�}tj�}|r0tj|�}tjd|d|�tjd|�dS)Nr�r��	changelog)r�r�_iter_log_onelineZ_iter_changelogZwrite_git_changelogZgenerate_authors)rRr�r�rrrrQ�srQc@s(eZdZdZdZdd�ZdS)�
LocalSDistz5Builds the ChangeLog and Authors files from VC first.r	cCs!t|j�tjj|�dS)N)rQrRr	rS)rTrrrrS�s
zLocalSDist.runN)rUrVrWrXrYrSrrrrr��sr�)�builddoccCstS)N)�_have_sphinxrrrr�have_sphinx�sr�c	s*i�|r|d}nd}tjd|g|�}td���fdd�|jd�D�}t�}x1|D])}|jdd�|jd	�D��quW�fd
d�}|d|d
�|d|d�|d|d�|d|d�x|D]}tjd|�q�W�jd
d��S)aCalculate the sort of semver increment needed from git history.

    Every commit from HEAD to tag is consider for Sem-Ver metadata lines.
    See the pbr docs for their syntax.

    :return: a dict of kwargs for passing into SemanticVersion.increment.
    z..HEADZHEADrz    sem-ver:cs;g|]1}|j�jd�r|�d�j��qS)z    sem-ver:N)�lowerrDr)rrM)�
header_lenrrr2�s	z)_get_increment_kwargs.<locals>.<listcomp>r+cSsg|]}|j��qSr)r)r�symbolrrrr2�s	rcs'||kr#d�|<|j|�dS)NT)�discard)r��symbolsZimpact)�resultrr�_handle_symbol�s
z-_get_increment_kwargs.<locals>._handle_symbolZbugfixZpatchZfeature�minorZdeprecationz	api-break�majorz[pbr] Unknown Sem-Ver symbol %rN)	r�_run_git_commandrpr�set�updaterrL�pop)	�git_dir�tagZversion_specr�rgr�r�r�r�r)r�r�r�_get_increment_kwargs�s&
"	
'
r�c
Cs�tjd|�}d}x�t|�D]�\}\}}}t�}xFt|�D]8}y|jtjj|��WqPt	k
r�YqPXqPW|r%t
|�j�|fSq%Wd|fS)z�Return the commit data about the most recent tag.

    We use git-describe to find this out, but if there are no
    tags then we fall back to counting commits since the beginning
    of time.
    r�rr*)rr��	enumerater�r�addr�SemanticVersion�from_pip_string�	Exception�max�release_string)r�r�Z	row_countZignoredZtag_setZversion_tagsr�rrr�_get_revno_and_last_tags"	
	r�cCs�t|�\}}tjj|p$d�}|dkr?|}n|jt||��}|dk	r�||kr�tdtd|d|���|dkr�|S|j|�}|dk	r�|j|�}||kr�|S|S)a�Calculate a version from a target version in git_dir.

    This is used for untagged versions only. A new version is calculated as
    necessary based on git metadata - distance to tags, current hash, contents
    of commit messages.

    :param git_dir: The git directory we're working from.
    :param target_version: If None, the last tagged version (or 0 if there are
        no tags yet) is incremented as needed to produce an appropriate target
        version following semver rules. Otherwise target_version is used as a
        constraint - if semver rules would result in a newer version then an
        exception is raised.
    :return: A semver version object.
    �0rNzRgit history requires a target version of %(new)s, but target version is %(target)s�new�target)	r�rr�r�Z	incrementr�rJrqZto_dev)r��target_versionr�ZdistanceZlast_semverZnew_versionZnew_devZ
target_devrrr�_get_version_from_git_targets$	r�cCs�tj�}|r�y@tjddg|dd�jdd�}tjj|�}Wn3tk
r�|r}tjj|�}nd}YnXt||�}|j	�Syt
�SWntk
r�dSYnXdS)	a�Calculate a version string from git.

    If the revision is tagged, return that. Otherwise calculate a semantic
    version description of the tree.

    The number of revisions since the last tag is included in the dev counter
    in the version for untagged versions.

    :param pre_version: If supplied use this as the target version rather than
        inferring one from the last tag + commit messages.
    Zdescribez
--exact-matchZthrow_on_errorT�-rmNr*)rZ_run_git_functionsr��replacerr�r�r�r�r��unicode�	NameError)�pre_versionr�Ztaggedr�r�rrr�_get_version_from_git>s$
	

r�cCs�ddg}i}xm|D]e}yt|d�}Wnttfk
rOwYnXytj|�}Wqtjk
r}wYqXqW|jdd�|kr�dS|jdd�S)z�Get the version from package metadata if present.

    This looks for PKG-INFO if present (for sdists), and if not looks
    for METADATA (for wheels) and failing that will return None.
    zPKG-INFOZMETADATAr4�NameNZVersion)r5�IOError�OSError�emailZmessage_from_fileZMessageErrorr)�package_nameZpkg_metadata_filenamesZpkg_metadata�filenameZpkg_metadata_filerrr�_get_version_from_pkg_metadatads
r�cCs�tjjdtjjdd��}|r.|St|�}|rD|St|�}tjddkrr|jd�}|r||Std��dS)aGet the version of the project. First, try getting it from PKG-INFO or
    METADATA, if it exists. If it does, that means we're in a distribution
    tarball or that install has happened. Otherwise, if there is no PKG-INFO
    or METADATA file, pull the version from git.

    We do not support setup.py version sanity in git archive tarballs, nor do
    we support packagers directly sucking our git repo into theirs. We expect
    that a source tarball be made from our git repo - or that if someone wants
    to make a source tarball from a fork of our repo with additional tags in it
    that they understand and desire the results of doing that.

    :param pre_version: The version field from setup.cfg - if set then this
        version will be the next release.
    ZPBR_VERSIONZOSLO_PACKAGE_VERSIONNrrAzutf-8z�Versioning for this project requires either an sdist tarball, or access to an upstream git repository. Are you sure that git is installed?)	rrrr�r�r"r#�encoder�)r�r�rrrr�get_version|s	r�)rr)rr)LrXZ
__future__rZdistutils.commandrr[r�rr�rr:r"rGZ
setuptoolsZsetuptools.commandrrrrr	r�r
rrZpbr.pbr_jsonr
rr'ZTEST_REQUIREMENTS_FILESr)r0r3r8rFrOrPrZr^r\ZCommandr_rfZnosergrirhrj�ImportErrorrkZ
_wsgi_textZ_script_textrnr%�normpathrsrwrxr~Zmanifest_makerr�r�rQr�r�r�Z
LocalBuildDocZLocalBuildLatexr�r�r�r�r�r�r�Zpbr_jsonZwrite_pbr_jsonrrrr�<module>s�

@
	

'!(!	
	

%%&)

Filemanager

Name Type Size Permission Actions
__init__.cpython-35.opt-1.pyc File 95 B 0644
__init__.cpython-35.pyc File 95 B 0644
builddoc.cpython-35.opt-1.pyc File 6.58 KB 0644
builddoc.cpython-35.pyc File 6.58 KB 0644
core.cpython-35.opt-1.pyc File 2.94 KB 0644
core.cpython-35.pyc File 2.94 KB 0644
extra_files.cpython-35.opt-1.pyc File 620 B 0644
extra_files.cpython-35.pyc File 620 B 0644
find_package.cpython-35.opt-1.pyc File 721 B 0644
find_package.cpython-35.pyc File 721 B 0644
git.cpython-35.opt-1.pyc File 8.13 KB 0644
git.cpython-35.pyc File 8.13 KB 0644
options.cpython-35.opt-1.pyc File 412 B 0644
options.cpython-35.pyc File 412 B 0644
packaging.cpython-35.opt-1.pyc File 20.16 KB 0644
packaging.cpython-35.pyc File 20.16 KB 0644
pbr_json.cpython-35.opt-1.pyc File 632 B 0644
pbr_json.cpython-35.pyc File 632 B 0644
testr_command.cpython-35.opt-1.pyc File 4.63 KB 0644
testr_command.cpython-35.pyc File 4.63 KB 0644
util.cpython-35.opt-1.pyc File 15.43 KB 0644
util.cpython-35.pyc File 15.43 KB 0644
version.cpython-35.opt-1.pyc File 15.17 KB 0644
version.cpython-35.pyc File 15.17 KB 0644