Sindbad~EG File Manager

Current Path : /usr/local/lib/python3.12/site-packages/pip/_internal/commands/__pycache__/
Upload File :
Current File : //usr/local/lib/python3.12/site-packages/pip/_internal/commands/__pycache__/inspect.cpython-312.pyc

�

4Μgu����ddlZddlmZddlmZmZmZddlmZddl	m
Z
ddlmZddl
mZddlmZdd	lmZdd
lmZmZddlmZddlmZej4e�ZGd
�de�Zy)�N)�Values)�Any�Dict�List)�default_environment)�
print_json)�__version__)�
cmdoptions)�Command)�SUCCESS)�BaseDistribution�get_environment)�stdlib_pkgs)�path_to_urlc�T�eZdZdZdZdZdd�Zdedee	de
fd	�Zd
ede
e	effd�Zy)
�InspectCommandzZ
    Inspect the content of a Python environment and produce a report in JSON format.
    Tz
      %prog [options]�returnNc�(�|jjdddd��|jjddddd�	�|jjtj��|jjd
|j�y)Nz--local�
store_trueFzSIf in a virtualenv that has global access, do not list globally-installed packages.)�action�default�helpz--user�userz,Only output packages installed in user-site.)�destrrrr)�cmd_opts�
add_optionr
�	list_path�parser�insert_option_group)�selfs �I/usr/local/lib/python3.12/site-packages/pip/_internal/commands/inspect.py�add_optionszInspectCommand.add_optionss����
�
� � ����/�	!�	
�	
�
�
� � �����?�	!�	
�	
�
�
� � ��!5�!5�!7�8����'�'��4�=�=�9��options�argsc�J�tj|�t|j�j	|j
|jtt���}dt|D�cgc]}|j|���c}t�d�}t|��tScc}w)N)�
local_only�	user_only�skip�1)�version�pip_version�	installed�environment)�data)r
�check_list_path_optionr�path�iter_installed_distributions�localr�setrr	�
_dist_to_dictrrr)r r$r%�dists�dist�outputs      r!�runzInspectCommand.run0s����)�)�'�2�����-�J�J��}�}��l�l��[�!�K�
���&�?D�E�u�t�$�,�,�T�2�u�E�.�0�	
��	������Fs�(B r7c�.�|j|jd�}|j}|�|j�|d<n!|j}|�t|�ddid�|d<|j}|jr||d<|jr|j|d<|S)N)�metadata�metadata_location�
direct_url�editableT)�url�dir_info�	installer�	requested)	�
metadata_dict�
info_locationr=�to_dict�editable_project_locationrrA�installed_with_dist_inforB)r r7�resr=rFrAs      r!r5zInspectCommand._dist_to_dictAs����*�*�!%�!3�!3�
���_�_�
��!� *� 2� 2� 4�C���)-�(F�(F�%�(�4�&�'@�A�"�D�!�%��L�!��N�N�	��>�>�(�C����(�(�#�~�~�C����
r#)rN)�__name__�
__module__�__qualname__�__doc__�ignore_require_venv�usager"rr�str�intr9r
rrr5�r#r!rrsU�����
�E�:�(�6���c���s��"�"2��t�C��H�~�r#r)�logging�optparser�typingrrr�pip._vendor.packaging.markersr�pip._vendor.richr�pipr	�pip._internal.clir
�pip._internal.cli.base_commandr�pip._internal.cli.status_codesr�pip._internal.metadatar
r�pip._internal.utils.compatr�pip._internal.utils.urlsr�	getLoggerrI�loggerrrQr#r!�<module>r`sL����"�"�=�'��(�2�2�D�2�0�	��	�	�8�	$��I�W�Ir#

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists