%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /snap/core18/2887/usr/lib/python3.6/distutils/command/__pycache__/
Upload File :
Create Path :
Current File : //snap/core18/2887/usr/lib/python3.6/distutils/command/__pycache__/install_egg_info.cpython-36.pyc

3

��]�
�@sddZddlmZddlmZmZddlZddlZddlZGdd�de�Z	dd�Z
d	d
�Zdd�ZdS)
z�distutils.command.install_egg_info

Implements the Distutils 'install_egg_info' command, for installing
a package's PKG-INFO metadata.�)�Command)�log�dir_utilNc@s<eZdZdZdZddgZd	d
�Zdd�Zd
d�Zdd�Z	dS)�install_egg_infoz)Install an .egg-info file for the packagez8Install package's PKG-INFO metadata as an .egg-info file�install-dir=�d�directory to install to�install-layoutN�custom installation layoutcCsd|_d|_d|_dS)N)�install_dir�install_layout�
prefix_option)�self�r�8/usr/lib/python3.6/distutils/command/install_egg_info.py�initialize_optionssz#install_egg_info.initialize_optionscCs�|jdd�|jdd�|jdd�|jrP|jj�dkr@td��|jj�dk}n|jr\d	}nd
}|r�dtt|jj���tt	|jj
���f}n6dtt|jj���tt	|jj
���ftjdd
��}t
jj|j|�|_|jg|_dS)NZinstall_librZinstallrr
�deb�unixz"unknown value for --install-layoutFTz%s-%s.egg-infoz%s-%s-py%d.%d.egg-info�)rr)rr)r
r
)rr)Zset_undefined_optionsr�lowerZDistutilsOptionErrorr
�to_filename�	safe_name�distributionZget_name�safe_versionZget_version�sys�version_info�os�path�joinr�target�outputs)rZno_pyver�basenamerrr�finalize_optionss*z!install_egg_info.finalize_optionsc	Cs�|j}tjj|�r2tjj|�r2tj||jd�nNtjj|�rX|j	tj
|jfd|�n(tjj|j�s�|j	tj|jfd|j�t
jd|�|js�t|ddd��}|jjj|�WdQRXdS)N)�dry_runz	Removing z	Creating z
Writing %s�wzUTF-8)�encoding)rrr�isdir�islinkrZremove_treer#�existsZexecute�unlinkr�makedirsr�info�openrZmetadataZwrite_pkg_file)rr�frrr�run4szinstall_egg_info.runcCs|jS)N)r )rrrr�get_outputsBszinstall_egg_info.get_outputs)rrr)r	Nr
)
�__name__�
__module__�__qualname__�__doc__ZdescriptionZuser_optionsrr"r.r/rrrrrsrcCstjdd|�S)z�Convert an arbitrary string to a standard distribution name

    Any runs of non-alphanumeric/. characters are replaced with a single '-'.
    z[^A-Za-z0-9.]+�-)�re�sub)�namerrrrJsrcCs|jdd�}tjdd|�S)z�Convert an arbitrary string to a standard version string

    Spaces become dots, and all other non-alphanumeric characters become
    dashes, with runs of multiple dashes condensed to a single dash.
    � �.z[^A-Za-z0-9.]+r4)�replacer5r6)�versionrrrrRsrcCs|jdd�S)z|Convert a project or version name to its filename-escaped form

    Any '-' characters are currently replaced with '_'.
    r4�_)r:)r7rrrr\sr)
r3Z
distutils.cmdrZ	distutilsrrrrr5rrrrrrrr�<module>s?

Zerion Mini Shell 1.0