Hacked By AnonymousFox

Current Path : /opt/alt/python311/lib64/python3.11/distutils/__pycache__/
Upload File :
Current File : //opt/alt/python311/lib64/python3.11/distutils/__pycache__/cmd.cpython-311.opt-2.pyc

�

c��f�F��n�	ddlZddlZddlZddlmZddlmZmZmZm	Z	m
Z
ddlmZGd�d��ZdS)�N)�DistutilsOptionError)�util�dir_util�	file_util�archive_util�dep_util��logc��eZdZ	gZd�Zd�Zd�Zd�Zd�Zd$d�Z	d	�Z
d%d�Zd�Zd&d
�Z
d&d�Zd�Z	d&d�Zd�Zd�Zd�Zd�Zd%d�Zd'd�Zd�Zd�Zd�Zd(d�Zd)d�Z		d*d�Z		d+d�Zd%d �Zd,d!�Z		d-d"�Z 	d.d#�Z!dS)/�Commandc��	ddlm}t||��std���|jt
urt
d���||_|���d|_	|j
|_
d|_d|_d|_
dS)Nr)�Distributionz$dist must be a Distribution instancezCommand is an abstract class)�distutils.distr�
isinstance�	TypeError�	__class__r�RuntimeError�distribution�initialize_options�_dry_run�verbose�force�help�	finalized)�self�distrs   �4/opt/alt/python311/lib64/python3.11/distutils/cmd.py�__init__zCommand.__init__/s���	�	0�/�/�/�/�/��$��-�-�	D��B�C�C�C��>�W�$�$��=�>�>�>� ������!�!�!���
��|�����
���	������c��|dkr,t|d|z��}|�t|j|��S|St|���)N�dry_run�_)�getattrr�AttributeError)r�attr�myvals   r�__getattr__zCommand.__getattr___sK���9����D�#��*�-�-�E��}��t�0�$�7�7�7��� ��&�&�&rc�J�|js|���d|_dS�N�)r�finalize_options�rs r�ensure_finalizedzCommand.ensure_finalizedis)���~�	$��!�!�#�#�#�����rc�2�	td|jz����Nz,abstract method -- subclass %s must override�rrr,s rrzCommand.initialize_options{�(��	��I�!�^�,�-�-�	-rc�2�	td|jz���r/r0r,s rr+zCommand.finalize_options�s(��		��I�!�^�,�-�-�	-rN�c�z�ddlm}|�d|���z}|�||ztj���|dz}|jD]j\}}}|�|��}|ddkr
|dd�}t||��}|�||�d|��ztj����kdS)	Nr)�
longopt_xlatezcommand options for '%s':)�levelz  ����=z = )	�distutils.fancy_getoptr5�get_command_name�announcer
�INFO�user_options�	translater#)r�header�indentr5�optionr"�values       r�dump_optionszCommand.dump_options�s���8�8�8�8�8�8��>�0�4�3H�3H�3J�3J�J�F��
�
�f�v�o�S�X�
�6�6�6��$���"�/�	*�	*�N�V�Q���%�%�m�4�4�F��b�z�S� � ��������D�&�)�)�E��M�M�&������#>�>� #��
�
*�
*�
*�
*�	*�	*rc�2�	td|jz���r/r0r,s r�runzCommand.run�r1rr*c�2�	tj||��dS�Nr	)r�msgr6s   rr;zCommand.announce�s!��	�	���s�����rc�v�	ddlm}|r/t|��tj���dSdS)Nr)�DEBUG)�distutils.debugrJ�print�sys�stdout�flush)rrHrJs   r�debug_printzCommand.debug_print�sR��	�	*�)�)�)�)�)��	��#�J�J�J��J��������	�	rc	��t||��}|�t|||��|St|t��st	d|�d|�d|�d����|S)N�'z' must be a z (got `z`))r#�setattrr�strr)rrA�what�default�vals     r�_ensure_stringlikezCommand._ensure_stringlike�sq���d�F�#�#���;��D�&�'�*�*�*��N��C��%�%�	>�&�&�*0�&�&�$�$�$����(=�>�>�
>��
rc�6�	|�|d|��dS)N�string)rX)rrArVs   r�
ensure_stringzCommand.ensure_string�s'��	�	
�����'�:�:�:�:�:rc�8�	t||��}|�dSt|t��r&t||t	jd|����dSt|t��rtd�|D����}nd}|std|�d|�d����dS)Nz,\s*|\s+c3�@K�|]}t|t��V��dSrG)rrT)�.0�vs  r�	<genexpr>z-Command.ensure_string_list.<locals>.<genexpr>�s,����9�9���A�s�+�+�9�9�9�9�9�9rFrRz!' must be a list of strings (got �))	r#rrTrS�re�split�list�allr)rrArW�oks    r�ensure_string_listzCommand.ensure_string_list�s���	�
�d�F�#�#���;��F�
��S�
!�
!�
	'��D�&�"�(�;��"<�"<�=�=�=�=�=��#�t�$�$�
��9�9�S�9�9�9�9�9������
'�*�*�������&�'�'�'�
'�
'rc��|�|||��}|�"||��std|z||fz���dSdS)Nzerror in '%s' option: )rXr)rrA�testerrU�	error_fmtrVrWs       r�_ensure_tested_stringzCommand._ensure_tested_string�s[���%�%�f�d�G�<�<���?�6�6�#�;�;�?�&�(@�9�(L�*0�#��(7�8�8�
8��?�?�?rc�V�	|�|tjjdd��dS)N�filenamez$'%s' does not exist or is not a file)rk�os�path�isfile�rrAs  r�ensure_filenamezCommand.ensure_filename�s:��C��"�"�6�2�7�>�#-�#I�	K�	K�	K�	K�	Krc�T�|�|tjjdd��dS)Nzdirectory namez)'%s' does not exist or is not a directory)rkrnro�isdirrqs  r�ensure_dirnamezCommand.ensure_dirnames7���"�"�6�2�7�=�#3�#N�	P�	P�	P�	P�	Prc�H�t|d��r|jS|jjS)N�command_name)�hasattrrwr�__name__r,s rr:zCommand.get_command_name	s(���4��(�(�	+��$�$��>�*�*rc	���	|j�|��}|���|D]4\}}t||���t	||t||�����5dSrG)r�get_command_objr-r#rS)r�src_cmd�option_pairs�src_cmd_obj�
src_option�
dst_options      r�set_undefined_optionszCommand.set_undefined_optionss���	��'�7�7��@�@���$�$�&�&�&�(4�	L�	L�$�Z���t�Z�(�(�0���j�'�+�z�*J�*J�K�K�K��	L�	Lrc�f�	|j�||��}|���|SrG)rr{r-)r�command�create�cmd_objs    r�get_finalized_commandzCommand.get_finalized_command$s8��	�
�#�3�3�G�V�D�D��� � �"�"�"��rrc�8�|j�||��SrG)r�reinitialize_command)rr��reinit_subcommandss   rr�zCommand.reinitialize_command0s%��� �5�5�g�6H�J�J�	Jrc�<�	|j�|��dSrG)r�run_command)rr�s  rr�zCommand.run_command4s&��	�	
��%�%�g�.�.�.�.�.rc�j�	g}|jD]'\}}|�||��r|�|���(|SrG)�sub_commands�append)r�commands�cmd_name�methods    r�get_sub_commandszCommand.get_sub_commands;sN��	���"&�"3�	*�	*��X�v��~������~�����)�)�)���rc�V�tjd|���|��dS)Nzwarning: %s: %s
)r
�warnr:)rrHs  rr�zCommand.warnKs)����$�d�&;�&;�&=�&=�s�C�C�C�C�Crc�@�tj||||j���dS�N�r!)r�executer!)r�func�argsrHr6s     rr�zCommand.executeNs#����T�4��d�l�;�;�;�;�;�;r�c�>�tj|||j���dSr�)r�mkpathr!)r�name�modes   rr�zCommand.mkpathQs!�����d�D�L�9�9�9�9�9�9rc	�P�	tj|||||j||j���Sr�)r�	copy_filerr!)r�infile�outfile�
preserve_mode�preserve_times�linkr6s       rr�zCommand.copy_fileTs:��	L��"�6�7�M�#1�t�z�>�4�+/�<�9�9�9�	9rc	�P�	tj||||||j|j���Sr�)r�	copy_treerr!)rr�r�r�r��preserve_symlinksr6s       rr�zCommand.copy_tree]s>��	��!�&�'�=�"0�2C�&*�j�.�$�,�H�H�H�	Hrc�<�	tj|||j���Sr�)r�	move_filer!)r�src�dstr6s    rr�zCommand.move_filefs��2��"�3��T�\�B�B�B�Brc�:�	ddlm}||||j���dS)Nr)�spawnr�)�distutils.spawnr�r!)r�cmd�search_pathr6r�s     rr�z
Command.spawnjs6��@�)�)�)�)�)�)�
��c�;���5�5�5�5�5�5rc	�B�tj|||||j||���S)N)r!�owner�group)r�make_archiver!)r�	base_name�format�root_dir�base_dirr�r�s       rr�zCommand.make_archiveos2���(��F�H�h�15��/4�E�C�C�C�	Crc�l�	|�d|z}t|t��r|f}n+t|ttf��st	d���|�d|�dd�|����}|jstj||��r|�	||||��dStj|��dS)Nzskipping %s (inputs unchanged)z9'infiles' must be a string, or a list or tuple of stringszgenerating z from z, )rrTrd�tupler�joinrr�newer_groupr�r
�debug)r�infilesr�r�r��exec_msg�skip_msgr6s        r�	make_filezCommand.make_fileus���	���7�'�A�H��g�s�#�#�	O��j�G�G��G�d�E�]�3�3�	O��M�O�O�
O����29�'�'�4�9�9�W�;M�;M�;M�N�H�
�:�	 ��-�g�w�?�?�	 ��L�L��t�X�u�5�5�5�5�5�
�I�h�����r)Nr3)r*rG)rr))r�)r*r*Nr*)r*r*rr*)r*r*)NNNN)NNr*)"ry�
__module__�__qualname__r�rr'r-rr+rCrEr;rPrXr[rgrkrrrur:r�r�r�r�r�r�r�r�r�r�r�r�r�r��rrrrsr������
�:�L�
-�-�-�`'�'�'����$-�-�-�-�-�-�*�*�*�*�-�-�-��������.����;�;�;�;�'�'�'�,'+�8�8�8�8�K�K�K�P�P�P�+�+�+�L�L�L�*����J�J�J�J�/�/�/���� D�D�D�<�<�<�<�:�:�:�:�JK�#$�9�9�9�9�JK�./�H�H�H�H�C�C�C�C�6�6�6�6�
GK�'+�C�C�C�C�78� � � � � � rr)
rMrnrb�distutils.errorsr�	distutilsrrrrrr
rr�rr�<module>r�s����������������1�1�1�1�1�1�G�G�G�G�G�G�G�G�G�G�G�G�G�G�������G �G �G �G �G �G �G �G �G �G r

Hacked By AnonymousFox1.0, Coded By AnonymousFox