관리-도구
편집 파일: entrypoints.cpython-312.pyc
� G��eC � � � d dl Z d dlZd dlZd dlZd dlmZmZ d dlmZ d dl m Z ddej j � �dej j � dej j � �gZe r4ddhZ e j ee� D � cg c] } dj# | � �� c} Zdd eee d edefd�Zdefd �Zdefd�Zyc c} w )� N)�List�Optional)�main)�WINDOWS�pip�.� z.exe�args�_nowarn�returnc �Z � |st j j d� t | � S )a� Central wrapper for all old entrypoints. Historically pip has had several entrypoints defined. Because of issues arising from PATH, sys.path, multiple Pythons, their interactions, and most of them having a pip installed, users suffer every time an entrypoint gets moved. To alleviate this pain, and provide a mechanism for warning users and directing them to an appropriate place for help, we now define all of our old entrypoints as wrappers for the current one. a WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip. Please see https://github.com/pypa/pip/issues/5599 for advice on fixing the underlying issue. To avoid this problem you can invoke Python with '-m pip' instead of running pip directly. )�sys�stderr�writer )r r s ��/builddir/build/BUILDROOT/alt-python312-pip-23.3.1-1.el8.x86_64/opt/alt/python312/lib/python3.12/site-packages/pip/_internal/utils/entrypoints.py�_wrapperr s* � � �� � ��� &� � ��:�� c � � t rdnd} t j j t j | � }t j j t j j dd� � j t j � }t j j |� |v }|r�t D ]~ }t j |� }t j j ||� }|s�;t j j |� s�[t j j ||� s�||c S t! � � d�S )zHTry to figure out the best way to invoke pip in the current environment.�Scripts�bin�PATHr z -m pip)r �os�path�joinr �prefix�normcase�environ�get�split�pathsep�_EXECUTABLE_NAMES�shutil�which�exists�samefile�#get_best_invocation_for_this_python)�binary_directory� binary_prefix� path_parts�exe_are_in_PATH�exe_name�found_executable�binary_executables r � get_best_invocation_for_this_pipr. / s� � �$+�y����G�G�L�L����-=�>�M� ���!�!�"�*�*�.�.���"<�=�C�C�B�J�J�O�J��g�g�&�&�}�5��C�O��)� �H�%�|�|�H�5�� "�����]�H� E�� ��G�G�N�N�#4�5��G�G�$�$�$�%�� �� � 2�3� 4�G�<�<r c �� � t j } t j j | � }t j |� }|r"t j j || � r|S | S )z<Try to figure out the best way to invoke the current Python.)r � executabler r �basenamer"