File manager - Edit - /opt/saltstack/salt/lib/python3.10/site-packages/virtualenv/run/__pycache__/__init__.cpython-310.pyc
Back
o ;j? � @ sH d dl mZ d dlZd dlZd dlmZ d dlmZ d dlm Z d dl mZmZ d dl mZmZ d dlmZ d d lmZ d d lmZ ddlmZ dd lmZ ddlmZ ddlmZ erhd dlmZ ddl m!Z! d3d4dd�Z" d3d4dd �Z# d5d6d#d$�Z$d7d8d&d'�Z%d9d*d+�Z&d:d-d.�Z'd;d/d0�Z(d<d1d2�Z)dd gZ*dS )=� )�annotationsN)�partial)� TYPE_CHECKING)� make_app_data)�VirtualEnvConfigParser�VirtualEnvOptions)�LEVELS�setup_report)�Session)�manual_upgrade)�__version__� )�ActivationSelector)�CreatorSelector)�get_discover)�SeederSelector)�MutableMapping)�ComponentBuilderT�args� list[str]�options�VirtualEnvOptions | None� setup_logging�bool�env�MutableMapping[str, str] | None�returnr c C sR |du rt jn|}t| |||�}|� |�� W d � |S 1 s"w Y |S )a� Create a virtual environment given some command line interface arguments. :param args: the command line arguments :param options: passing in a ``VirtualEnvOptions`` object allows return of the parsed options :param setup_logging: ``True`` if setup logging handlers, ``False`` to use handlers already registered :param env: environment variables to use :returns: the session object of the creation (its structure for now is experimental and might change on short notice) N)�os�environ�session_via_cli�run)r r r r Z of_session� r! �K/opt/saltstack/salt/lib/python3.10/site-packages/virtualenv/run/__init__.py�cli_run s ��r# c sl |du rt jn|}t| � ||�\}}|�| �� |jj� _t� fdd�|D ��\}}}t� j � j |j|||�S )as Create a virtualenv session (same as cli_run, but this does not perform the creation). Use this if you just want to query what the virtual environment would look like, but not actually create it. :param args: the command line arguments :param options: passing in a ``VirtualEnvOptions`` object allows return of the parsed options :param setup_logging: ``True`` if setup logging handlers, ``False`` to use handlers already registered :param env: environment variables to use :returns: the session object of the creation (its structure for now is experimental and might change on short notice) Nc 3 s � | ]}|� � �V qd S �N)�create)�.0�e�r r! r"