File manager - Edit - /opt/imunify360/venv/lib/python3.11/site-packages/pip/_internal/vcs/__pycache__/versioncontrol.cpython-311.pyc
Back
� L�iGX � � � d Z ddlmZ ddlZddlZddlZddlZddlZddl m Z mZmZ ddl mZmZ ddlmZmZmZ ddlmZ ddlmZmZ dd lmZmZmZmZmZmZm Z m!Z! dd l"m#Z#m$Z$m%Z%m&Z& dgZ' ej( e)� � Z*e+ee, ee, f Z-d&d�Z. d'd(d�Z/d)d�Z0 G d� de1� � Z2 G d� de1� � Z3 ed�� � G d � d!� � � � Z4 G d"� d#� � Z5 e5� � Z6 G d$� d%� � Z7dS )*z)Handles all VCS (version control) support� )�annotationsN)�Iterable�Iterator�Mapping)� dataclass�field)�Any�Literal�Optional)�SpinnerInterface)� BadCommand�InstallationError)� HiddenText�ask_path_exists� backup_dir�display_path�hide_url� hide_value�is_installable_dir�rmtree)�CommandArgs�call_subprocess�format_command_args�make_command�vcs�name�str�return�boolc �x � t j � | � � j }|sdS |g d�t j z v S )z3 Return true if the name looks like a URL. F)�http�https�file�ftp)�urllib�parse�urlsplit�schemer �all_schemes)r r( s ��/builddir/build/BUILD/imunify360-venv-2.6.1/opt/imunify360/venv/lib/python3.11/site-packages/pip/_internal/vcs/versioncontrol.py�is_urlr+ - sB � � �\� "� "�4� (� (� /�F�� ��u��5�5�5���G�G�G� �repo_url�rev�project_name�subdir� str | Nonec � � t j � |d� � }|� dd� � }| � d|� d|� �}|r|d|� �z }|S )z� Return the URL for a VCS requirement. Args: repo_url: the remote VCS url, with any needed VCS prefix (e.g. "git+"). project_name: the (unescaped) project name. �/�-�_�@z#egg=z&subdirectory=)r% r&