403Webshell
Server IP : 54.37.205.81  /  Your IP : 216.73.216.76
Web Server : nginx/1.22.1
System : Linux vps-249481fa 6.1.0-50-cloud-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.176-1 (2026-07-02) x86_64
User : debian ( 1000)
PHP Version : 8.2.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/pipx/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/pipx/__pycache__/main.cpython-311.pyc
�

�'�c�p�	�f�dZddlZddlZddlZddlZddlZddlZddlZddlZddl	Z	ddl
Zddlm
Z
ddlmZmZmZmZddlZddlmZmZddlmZddlZddlmZmZddlmZmZdd	l m!Z!m"Z"dd
lm#Z#m$Z$ddl%m&Z&ddl'm(Z(dd
l)m*Z*m+Z+m,Z,m-Z-ddl.m/Z/ddl0m1Z1ej2e3��Z4ee5gee5fZ6dFd�Z7ej8d��Z9ej8de5ej:���de5ej;���d���Z<e<e,ddd���z
Z<ej=de(��Z>ej8dej?�dej@�de>�d���ZAGd�d ejB��ZCGd!�d"��ZDd#ee5e5fdee5fd$�ZEd#ee5e5fdee5fd%�ZFd&ejGde$fd'�ZHd(ejIddfd)�ZJd(ejIddfd*�ZKd+ejLddfd,�ZMd-e6ddfd.�ZNd-e6ddfd/�ZOd+ejLddfd0�ZPd-e6ddfd1�ZQd+ejLddfd2�ZRd-e6ddfd3�ZSd+ejLddfd4�ZTd+ejLddfd5�ZUd+ejLddfd6�ZVd-e6ddfd7�ZWd+ejLddfd8�ZXd+ejLddfd9�ZYdejIfd:�ZZd;ee
d<e[ddfd=�Z\de
fd>�Z]d?e^ddfd@�Z_d&ejGddfdA�Z`dBejGddfdC�Zade$fdD�Zbe3dEkrejceb����dSdS)Gz"The command line interface to pipx�N)�Path)�Any�Callable�Dict�List)�InvalidRequirement�Requirement��canonicalize_name)�commands�	constants)�hide_cursor�show_cursor)�bold�green)�WINDOWS�ExitCode)�hazard)�DEFAULT_PYTHON)�	PipxError�mkdir�	pipx_wrap�rmdir)�
VenvContainer)�__version__�returnc�.�tt��dS�N)�printr���+/usr/lib/python3/dist-packages/pipx/main.py�
print_versionr#&s��	�+�����r!z�    The package name or specific installation source passed to pip.
    Runs `pip install -U SPEC`.
    For example `--spec mypackage==2.0.0` or `--spec  git+https://github.com/user/repo.git@branch`
    z�
    Install and execute apps from Python packages.

    Binaries can either be installed globally into isolated Virtual Environments
    or run directly in a temporary Virtual Environment.

    Virtual Environment location is z%.
    Symlinks to apps are placed in z.

    a�
    optional environment variables:
      PIPX_HOME             Overrides default pipx location. Virtual Environments will be installed to $PIPX_HOME/venvs.
      PIPX_BIN_DIR          Overrides location of app installations. Apps are symlinked or copied here.
      PIPX_DEFAULT_PYTHON   Overrides default python used for commands.
      USE_EMOJI             Overrides emoji behavior. Default value varies based on platform.
    z                        T)�subsequent_indent�
keep_newlines�PIPX__DOC_DEFAULT_PYTHONa
    The install command is the preferred way to globally install apps
    from python packages on your system. It creates an isolated virtual
    environment for the package, then ensures the package's apps are
    accessible on your $PATH.

    The result: apps you can run from anywhere, located in packages
    you can cleanly upgrade or uninstall. Guaranteed to not have
    dependency version conflicts or interfere with your OS's python
    packages. 'sudo' is not required to do this.

    pipx install PACKAGE_NAME
    pipx install --python PYTHON PACKAGE_NAME
    pipx install VCS_URL
    pipx install ./LOCAL_PATH
    pipx install ZIP_FILE
    pipx install TAR_GZ_FILE

    The PACKAGE_SPEC argument is passed directly to `pip install`.

    The default virtual environment location is z�
    and can be overridden by setting the environment variable `PIPX_HOME`
    (Virtual Environments will be installed to `$PIPX_HOME/venvs`).

    The default app location is z� and can be
    overridden by setting the environment variable `PIPX_BIN_DIR`.

    The default python executable used to install a package is
    zZ and can be overridden
    by setting the environment variable `PIPX_DEFAULT_PYTHON`.
    c�.�eZdZdededeefd�ZdS)�LineWrapRawTextHelpFormatter�text�widthrc��|j�d|�����}tj||��S)N� )�_whitespace_matcher�sub�strip�textwrap�wrap)�selfr)r*s   r"�_split_linesz)LineWrapRawTextHelpFormatter._split_linesps8���'�+�+�C��6�6�<�<�>�>���}�T�5�)�)�)r!N)�__name__�
__module__�__qualname__�str�intrr3r r!r"r(r(osA������*��*�S�*�T�#�Y�*�*�*�*�*�*r!r(c�>�eZdZdeddfd�Zdededeefd�ZdS)�InstalledVenvsCompleter�venv_containerrNc�f�d�t|�����D��|_dS)Nc�6�g|]}t|j����Sr )r7�name)�.0�ps  r"�
<listcomp>z4InstalledVenvsCompleter.__init__.<locals>.<listcomp>ws ��V�V�V���Q�V���V�V�Vr!)�sorted�iter_venv_dirs�packages)r2r;s  r"�__init__z InstalledVenvsCompleter.__init__vs/��V�V�f�^�5R�5R�5T�5T�.U�.U�V�V�V��
�
�
r!�prefix�kwargsc�*���fd�|jD��S)Nc���g|]?}|�t������$��|t���d�����@Sr)�
startswithr�len)r?�xrFs  �r"rAz/InstalledVenvsCompleter.use.<locals>.<listcomp>zs]���
�
�
���|�|�-�f�5�5�6�6�
��(�q��V������(�(�
�
�
r!)rD)r2rFrGs ` r"�usezInstalledVenvsCompleter.useys0���
�
�
�
��]�
�
�
�	
r!)	r4r5r6rrEr7rrrMr r!r"r:r:usi������W�}�W��W�W�W�W�
�#�
��
��c��
�
�
�
�
�
r!r:�parsed_argsc��g}|�d��r
|d|dgz
}|�d��r3|tj|�dd��t���z
}|�d��r|dgz
}|S)N�	index_url�--index-url�pip_args�)�posix�editable�
--editable)�get�shlex�splitr)rNrRs  r"�get_pip_argsrZ�s����H����{�#�#�>��]�K��$<�=�=�����z�"�"�T��E�K����
�B� ?� ?�7�{�S�S�S�S�����z�"�"�#��\�N�"���Or!c�@�g}|�d��r|dgz
}|S)N�system_site_packages�--system-site-packages)rW)rN�	venv_argss  r"�
get_venv_argsr_�s0���I����-�.�.�0��.�/�/�	��r!�argsc
�	�d|vr|jnd}tt|����}tt|����}t	t
j��}d|vr�|j}tj	�
|��jrtd���d|vrK|j
�Dtj	�
|j
��jrd|j
vr|j
d|��z|_
|�|��}t�d|����d|vrd	�|jD��}|jd
kr�d|vr|j
�|j
n|jd}	t)|jd��j}	n#t,$r|jd}	YnwxYw|j}
t1j|	||jdd�|j|||j||
�	�	t9d��S|jd
krBt1jdd|jt
j|j||||j |j!|j"���S|jdkr0t1j#|d|j$|||j%|j!|j ���S|jdkr#t1j&||||j'|j ���S|jdkr#t1j(|||j'||j ���S|jdkr&t1j)||j'|j*|j+��S|jdkr t1j,|t
j|��S|jdkr t1j-|t
j|��S|jdkr't1j.|t
j|j|���S|jdkr(t1j/|t
j|j||���S|jdkr2|std���t1j0|||j1|j��S|jdkrg	t1j2|j ���S#tf$r?}t�4d d!�"��ttk|��d�#���d}~wwxYw|jd$kr(tmt
j7��t9d��S|jd%krt1j8|j9�&��Std'|j�����)(N�verboseF�packagezPackage cannot be a url�specz#egg=z Virtual Environment location is �skipc�,�g|]}t|����Sr r
)r?rLs  r"rAz$run_pipx_command.<locals>.<listcomp>�s!��=�=�=�a�&�q�)�)�=�=�=r!�runr��install)�force�include_dependencies�suffix�inject)rb�include_appsrkrj�upgrade)�include_injectedrj�upgrade-all)rprerj�list�	uninstall�
uninstall-all�	reinstall)�venv_dir�
local_bin_dir�pythonrb�
reinstall-all)re�runpipz)Developer error: venv_dir is not defined.�
ensurepath)rj�Uncaught Exception:T��exc_info)�wrap_message�completions�environment)�valuezUnknown command ):rbrZ�varsr_rr
�PIPX_LOCAL_VENVSrc�urllib�parse�urlparse�schemerrd�get_venv_dir�logger�infore�command�
app_with_argsr	r>r�no_cacherrgrx�
pypackagesrri�package_spec�
LOCAL_BIN_DIRrj�include_depsrlrm�dependenciesrnrorp�upgrade_all�
list_packages�json�shortrs�
uninstall_allru�
reinstall_all�run_pip�pipargs�ensure_pipx_paths�	Exception�debugr7r�completion_instructionsr�r�)r`rbrRr^r;rcrv�	skip_list�package_or_url�package_name�	use_cache�es            r"�run_pipx_commandr��s6��'�4�/�/�d�l�l�U�G��D��J�J�'�'�H��d�4�j�j�)�)�I�"�9�#=�>�>�N��D����,���<� � ��)�)�0�	7��5�6�6�6��T�>�>�d�i�3��|�$�$�T�Y�/�/�6�
>��$�)�+�+� $�	�,=�G�,=�,=� =�D�I�!�.�.�w�7�7�����A�x�A�A�B�B�B�
��~�~�=�=�4�9�=�=�=�	��|�u����$���4�9�#8�
�I�I��#�A�&�	�	1�&�t�'9�!�'<�=�=�B�L�L��!�	1�	1�	1� �-�a�0�L�L�L�	1����
�
�%�	�������q�r�r�"��K����O���
	
�
	
�
	
���{�{��	
���	"�	"��������#��K�����*�!%�!2��;�
�
�
�	
�
���	!�	!����������*�!%�!2��*�	
�	
�	
�		
�
���	"�	"������!�2��*�
�
�
�	
�
���	&�	&��#���!�2���*�
�
�
�	
�
���	�	��%��D�1�4�9�d�j�
�
�	
�
���	$�	$��!�(�I�,C�W�M�M�M�	
���	(�	(��%�n�i�6M�w�W�W�W�	
���	$�	$��!��#�1��;��	
�
�
�	
�
���	(�	(��%���#��K���
�
�
�	
�
���	!�	!��	I��G�H�H�H�����4�<���N�N�N�	
���	%�	%�	8��-�D�J�?�?�?�?���	8�	8�	8��L�L�.��L�>�>�>��C��F�F��7�7�7�7�����	8����
���	&�	&�
�i�/�0�0�0���{�{��	
���	&�	&��#�$�*�5�5�5�5��9�4�<�9�9�:�:�:s*�E>�>F�F�>P�
Q!�":Q�Q!�parserc���|�ddd���|�ddd���|�d	d
dd���|�d
d���dS)Nr]�
store_truezDGive the virtual environment access to the system site-packages dir.��action�helprQz-iz Base URL of Python Package Index�r�rVz-ez"Install a project in editable mode�r�r�z
--pip-argszHArbitrary pip arguments to pass directly to pip install/upgrade commands��add_argument�r�s r"�add_pip_venv_argsr�s���
��� ��
S�����
���
�t�2T��U�U�U�
�����
1��	��������
W������r!c�6�|�ddd���dS)Nz--include-depsz"Include apps of dependent packagesr�r�r�r�s r"�add_include_dependenciesr�/s1��
����C�L������r!�
subparsersc��|�ddtt���}|�dd���t	|��|�dd�	��|�d
ddd�
��|�ddd���|�dt
d���t
|��dS)NrizInstall a package)r��formatter_class�descriptionr�z%package name or pip installation specr��	--verboser��r��--force�-f�=Modify existing virtual environment and files in PIPX_BIN_DIRr�z--suffixrSz}Optional suffix for virtual environment and executable names. NOTE: The suffix feature is experimental and subject to change.��defaultr��--pythonzlThe Python executable used to create the Virtual Environment and run the associated app/apps. Must be v3.6+.)�
add_parserr(�INSTALL_DESCRIPTIONr�r�rr��r�r@s  r"�_add_installr�5s�������
 �4�'�		�	�	�A��N�N�>�(O�N�P�P�P��Q�����N�N�;�|�N�4�4�4��N�N����
L�	�����N�N���
N�	�����N�N���
2�	�����a�����r!�venv_completerc�j�|�ddd���}||�dd���_|�dd	d
���|�dd
d���t|��t	|��|�ddd
d���|�dd
���dS)Nrmz5Install packages into an existing Virtual EnvironmentzBInstalls packages to an existing pipx-managed virtual environment.�r�r�rczDName of the existing pipx-managed Virtual Environment to inject intor�r��+z\the packages to inject into the Virtual Environment--either package name or pip package spec)�nargsr�z--include-appsr�z2Add apps from the injected packages onto your PATHr�r�r�r�r�r�)r�r��	completerr�r��r�r�r@s   r"�_add_injectr�Xs�������
D�X�	�	�	�A�!��N�N��
S������N�N���
k�����
�N�N���
A�����
�Q�����a�����N�N����
L�	�����N�N�;�|�N�4�4�4�4�4r!c��|�ddd���}||�d��_|�ddd�	��|�d
ddd�	��t|��|�d
d���dS)NrozUpgrade a packagezbUpgrade a package in a pipx-managed Virtual Environment by running 'pip install --upgrade PACKAGE'r�rc�--include-injectedr��>Also upgrade packages injected into the main app's environmentr�r�r�r�r�r�)r�r�r�r�r�s   r"�_add_upgrader�ws�������
 �x�	�	�	�A�
+9�A�N�N�9���'��N�N���
M�����
�N�N����
L�	�����a�����N�N�;�|�N�4�4�4�4�4r!c��|�ddd���}|�ddd���|�d	d
gd���|�d
ddd���|�dd���dS)NrqzGUpgrade all packages. Runs `pip install -U <pkgname>` for each package.zbUpgrades all packages within their virtual environments by running 'pip install --upgrade PACKAGE'r�r�r�r�r��--skipr��skip these packages�r�r�r�r�r�r�r�r��r�r�r�s  r"�_add_upgrade_allr��s�������
V�x�	�	�	�A�
�N�N���
M�����
�N�N�8�3��9N�N�O�O�O��N�N����
L�	�����N�N�;�|�N�4�4�4�4�4r!c��|�ddd���}||�d��_|�dd���dS)	NrszUninstall a packagezbUninstalls a pipx-managed Virtual Environment by deleting it and any files that point to its apps.r�rcr�r�r�)r�r�r�r�s   r"�_add_uninstallr��sW������
"�x�	�	�	�A�
+9�A�N�N�9���'��N�N�;�|�N�4�4�4�4�4r!c�d�|�ddd���}|�dd���dS)NrtzUninstall all packagesz#Uninstall all pipx-managed packagesr�r�r�r�r�r�s  r"�_add_uninstall_allr��sC������
%�9�	�	�	�A�
�N�N�;�|�N�4�4�4�4�4r!c��|�dtdtjd�����}||�d��_|�dtd���|�d	d
���dS)NruzReinstall a packagez�
            Reinstalls a package.

            Package is uninstalled, then installed with pipx install PACKAGE
            with the same options used in the original install of PACKAGE.

            �r�r�r�rcr��nThe Python executable used to recreate the Virtual Environment and run the associated app/apps. Must be v3.6+.r�r�r�r�)r�r(r0�dedentr�r�rr�s   r"�_add_reinstallr��s�������4�
"��O�
�
�
�		�
	�
	�A�+9�A�N�N�9���'��N�N���
>�	�����N�N�;�|�N�4�4�4�4�4r!c��|�dtdtjd�����}|�dt
d���|�dd	gd
���|�dd
���dS)NryzReinstall all packagesaV
            Reinstalls all packages.

            Packages are uninstalled, then installed with pipx install PACKAGE
            with the same options used in the original install of PACKAGE.
            This is useful if you upgraded to a new version of Python and want
            all your packages to use the latest as well.

            r�r�r�r�r�r�r�r�r�r�r�)r�r(r0r�r�rr�s  r"�_add_reinstall_allr��s�������4�
%��O�
�

�

�		�	�	�A� �N�N���
>�	�����N�N�8�3��9N�N�O�O�O��N�N�;�|�N�4�4�4�4�4r!c��|�ddd���}|�ddd���|���}|�d	dd
���|�ddd���|�d
d���dS)NrrzList installed packagesz*List packages and apps installed with pipxr�r�r�z6Show packages injected into the main app's environmentr�z--jsonz Output rich data in json format.z--shortzList packages only.r�r�)r�r��add_mutually_exclusive_group)r�r@�gs   r"�	_add_listr��s�������
&�@�	�	�	�A�
�N�N���
E�����
	
�&�&�(�(�A��N�N���,N������N�N�9�\�8M�N�N�N�N��N�N�;�|�N�4�4�4�4�4r!c
��|�dtdtjdtj�d������}|�ddd�	��|�d
dtjdg�
��|�ddd�	��|�dt���|�dd���|�dtd���t|��|�|���tjdd|�����|_tjdd|j��|_dS)Nrgz�Download the latest version of a package to a temporary virtual environment, then run an app from it. Also compatible with local `__pypackages__` directory (experimental).z�
            Download the latest version of a package to a temporary virtual environment,
            then run an app from it. The environment will be cached
            and re-used for up to a� days. This
            means subsequent calls to 'run' for the same package will be faster
            since they can re-use the cached Virtual Environment.

            In support of PEP 582 'run' will use apps found in a local __pypackages__
            directory, if present. Please note that this behavior is experimental,
            and acts as a companion tool to pythonloc. It may be modified or
            removed in the future. See https://github.com/cs01/pythonloc.
            r�z
--no-cacher�z5Do not re-use cached virtual environment if it existsr�r�zapp ...z5app/package name and any arguments to be passed to it)�metavarr�r�r�z--pypackagesz9Require app to be run from local __pypackages__ directoryz--specr�r�r�r�z@The Python version to run package's CLI app with. Must be v3.6+.r�)�	subparserz^usage: rSz\.\.\.)r�r(r0r�r
�#TEMP_VENV_EXPIRATION_THRESHOLD_DAYSr��argparse�	REMAINDER�	SPEC_HELPrr��set_defaults�rer.�format_usage�usager�s  r"�_add_runr�s������
�4�
(��O�
�$-�#P�
�
�
�

�

�	�	�	�A�.�N�N���
D�����
�N�N���� �
D�������N�N���
H�����
�N�N�8�)�N�,�,�,��N�N�;�|�N�4�4�4��N�N���
O�����
�a�����N�N�Q�N�����f�[�"�a�n�n�&6�&6�7�7�A�G��f�Y�	�1�7�3�3�A�G�G�Gr!c���|�ddd���}||�dd���_|�dtjgd�	��|�d
d���dS)
Nrzz7Run pip in an existing pipx-managed Virtual Environmentr�rczCName of the existing pipx-managed Virtual Environment to run pip inr�r�z#Arguments to forward to pip commandr�r�r�r�)r�r�r�r�r�r�s   r"�_add_runpipr�9s�������
F�M�	�	�	�A�!��N�N��
R������N�N��� ��
2�	�����N�N�;�|�N�4�4�4�4�4r!c�h�|�ddd���}|�dddd�	��dS)
Nr{zVEnsure directories necessary for pipx operation are in your PATH environment variable.aEnsure directory where pipx stores apps is in your PATH environment variable. Also if pipx was installed via `pip install --user`, ensure pipx itself is in your PATH. Note that running this may modify your shell's configuration file(s) such as '~/.bashrc'.r�r�r�r�zzAdd text to your shell's config file even if it looks like your PATH already contains paths to pipx and pipx-install apps.r�r�r�s  r"�_add_ensurepathr�Ls`������
)�
F�	�
	�
	�A��N�N����
I������r!c��|�dtdtjd�����}|�dddd�	��dS)
Nr�z1Print a list of variables used in pipx.constants.a	
            Available variables:
            PIPX_HOME, PIPX_BIN_DIR, PIPX_SHARED_LIBS, PIPX_LOCAL_VENVS, PIPX_LOG_DIR,
            PIPX_TRASH_DIR, PIPX_VENV_CACHEDIR

            Only PIPX_HOME and PIPX_BIN_DIR can be set by users in the above list.

            r�z--valuez-v�VARIABLEz Print the value of the variable.)r�r�)r�r(r0r�r�r�s  r"�_add_environmentr�fsj������4�A��O�
�	
�	
�		�	�	�A��N�N��4��2T������r!c�0�ttj��}t|��}t	jdtt���}t���d|_	|�
dd���}t|��t||j
��t||j
��t|��t!||j
��t#|��t%||j
��t'|��t)|��t+|��t-||j
��t/|��t1|��|�ddd	�
��|�ddd�
��|S)N�pipx)�progr�r�rhr�z.Get help for commands with pipx COMMAND --help)�destr�z	--versionr�zPrint version and exitr�r�z9Print instructions on enabling shell completions for pipxr�)rr
r�r:r��ArgumentParserr(�PIPX_DESCRIPTION�
splitlines�man_short_description�add_subparsersr�r�rMr�r�r�r�r�r�r�r�r�r�r�r�r�)r;�completer_venvsr�r�s    r"�get_command_parserr{s���"�9�#=�>�>�N�-�n�=�=�O�
�
$�
�4�$����F�
$4�#>�#>�#@�#@��#C�F� ��&�&�
�$T�'���J�������
�O�/�0�0�0���_�0�1�1�1��Z� � � ��:��2�3�3�3��z�"�"�"��:��2�3�3�3��z�"�"�"�
�j�����Z�����
�O�/�0�0�0��J�����Z� � � �
����L�?W��X�X�X�����
H�O�����
�Mr!�	file_list�keep_numberc��t|��}t|��|kr3|d|�D])}	|����#t$rY�$wxYwdSdSr)rBrK�unlink�FileNotFoundError)rr�
existing_files   r"�delete_oldest_logsr	�s����y�!�!�I�
�9�~�~��#�#�&�}���}�5�	�	�M�
��$�$�&�&�&�&��$�
�
�
���
����	$�#�	�	s�A�
A�Ac�$�d}tj�dd���tt	tj�d����|��tt	tj�d����|��t
jd��}tjd|�d�z}d	}|���r;|dkr5tjd|�d
|�d�z}|d	z
}|���r|dk�5|S)N�
T)�parents�exist_okzcmd_*[0-9].logzcmd_*_pip_errors.logz%Y-%m-%d_%H.%M.%S�cmd_z.logrh�_)	r
�PIPX_LOG_DIRrr	rr�glob�time�strftime�exists)�max_logs�datetime_str�log_file�counters    r"�setup_log_filer�s���H�
�� � ��� �=�=�=��t�I�2�7�7�8H�I�I�J�J�H�U�U�U���Y�
#�
(�
(�)?�
@�
@�A�A�8�����=�!4�5�5�L��%�(A�|�(A�(A�(A�A�H��G�
�/�/�
�
���"����)�,O�<�,O�,O�'�,O�,O�,O�O���1����/�/�
�
���"����Or!rbc	��tj���rtt	d����nd}t��tj_ddddd�d|dzdd�dddd�d	�d
|rdnd|rd
ndd�ddttjj��ddd�d�dddgdd�idd�}tj�|��dS)Nzpipx >rhzlogging.Formatterz	{message}�{)�class�format�stylez ({funcName}:{lineno}): {message}z;{relativeCreated: >8.1f}ms ({funcName}:{lineno}): {message})�stream_nonverbose�stream_verbose�filezlogging.StreamHandlerr r�INFO�WARNING)r�	formatter�levelzlogging.FileHandlerr!zutf-8�DEBUG)rr$�filename�encodingr%)�streamr!r�r))�handlersr%F)�version�
formattersr*�loggers�incremental)
�sys�stdout�isattyrrrr�r
�
pipx_log_filer7�logging�config�
dictConfig)rb�pipx_str�logging_configs   r"�
setup_loggingr8�s3��(+�
�(9�(9�(;�(;�I�t�E�(�O�O�$�$�$��H�#1�#3�#3�D�N� ��-�%��"�"�-�"�%G�G����-�W����
�
�&1�18�Q�-�-�>Q�#*�9���	���/�#���� <�=�=�#� ���


�

��(�F�);�g�N�N�O��E#�#�N�H�N���n�-�-�-�-�-r!c
��d|vr)|jr"t��tjd��t	d|vo|j��t�tj	d�����t�d�
tj�����t�dt����t�dtt������t!t"j��t!t"j��t!t"j��t"jdz}|���sYt�d	��d
}t-|d��5}|�|��ddd��n#1swxYwYt1t"jd��t"jd
z}|���rDt�t7dt8�dt;|���d�d�����dSdS)Nr+rrbz%Y-%m-%d %H:%M:%Sr,zpipx version is zDefault python interpreter is zCACHEDIR.TAGz&Adding CACHEDIR.TAG to cache directoryz�Signature: 8a477f597d28d172789f06886806bc55
# This file is a cache directory tag created by pipx.
# For information about cache directory tags, see:
#       https://bford.info/cachedir/
�wFzpipx-appz
                zA  A virtual environment for pipx was detected at
                z�. The 'pipx-app' package has been
                renamed back to 'pipx'
                (https://github.com/pypa/pipx/issues/82).
                z    )r$)r+r#r/�exitr8rbr�r�rr�join�argvr�r�reprrrr
r�r��PIPX_VENV_CACHEDIRr�open�writer�PIPX_TRASH_DIR�warningrrr7)r`�cachedir_tag�	signaturer!�old_pipx_venv_locations     r"�setuprG�sQ���D���T�\�������������)�t�#�4���5�5�5�
�L�L�D�M�"5�6�6�8�9�9�9�
�L�L�C�H�H�S�X�&�&�(�)�)�)�
�K�K�0�;�0�0�1�1�1�
�K�K�G��n�1E�1E�G�G�H�H�H�	�)�
$�%�%�%�	�)�
!�"�"�"�	�)�
&�'�'�'��/�.�@�L���� � �	"����=�>�>�>�
5�	��,��
$�
$�	"���J�J�y�!�!�!�	"�	"�	"�	"�	"�	"�	"�	"�	"�	"�	"����	"�	"�	"�	"�
�)�
"�E�*�*�*�&�7�*�D���$�$�&�&�
����������+�,�,����#*�
�
�
�
	
�
	
�
	
�
	
�
	
�
�
s�F8�8F<�?F<�parsed_pipx_argsc���|jdkrU|jr+|jddkr|j�d��|js|j�d��dSdSdS)Nrgrz--z)the following arguments are required: app)r�r��popr��error)rHs r"�
check_argsrLs�����5�(�(��)�	2�.>�.L�Q�.O�SW�.W�.W��*�.�.�q�1�1�1� �-�	��&�,�,�;�
�
�
�
�
�)�(�	�	r!c�.�	t��t��}tj|��|���}t|��t
|��|jsK|���td��t�d��t��St|��t�d��t��S#t$r�}tt!|��t"j���t�d|��d���td��cYd}~t�d��t��Sd}~wt&$r:td��cYt�d��t��St($rt�dd����wxYw#t�d��t��wxYw)	zEntry point from command linerhzpipx finished.)r!zPipxError: Tr}Nr|)rr�argcomplete�autocomplete�
parse_argsrGrLr��
print_helprr�r�rr�rrr7r/�stderr�KeyboardInterruptr�)r�rHr�s   r"�clirT's�����
�
�
�#�%�%��� ��(�(�(�!�,�,�.�.��
������#�$�$�$��'�	��������A�;�;�	���%�&�&�&��
�
�
�
� � 0�1�1�	���%�&�&�&��
�
�
�
������
�c�!�f�f�3�:�&�&�&�&����&�1�&�&���6�6�6���{�{������	���%�&�&�&��
�
�
�
�����������{�{���
	���%�&�&�&��
�
�
�
��������*�T��:�:�:�
������	���%�&�&�&��
�
�
�
���sC�BC-�6C-�-
G'�7AE:�G'�
G*�:G'�G*�'G'�'G*�**H�__main__)rN)d�__doc__r�r3�logging.config�osr�rXr/r0r�urllib.parser��pathlibr�typingrrrrrN�packaging.requirementsrr	�packaging.utilsr�pipx.constantsr�rr
�pipx.animaterr�pipx.colorsrrrr�pipx.emojisr�pipx.interpreterr�	pipx.utilrrrr�	pipx.venvr�pipx.versionr�	getLoggerr4r�r7�
VenvCompleterr#r�r�r�r�r��getenv�DOC_DEFAULT_PYTHON�DEFAULT_PIPX_HOME�DEFAULT_PIPX_BIN_DIRr��RawDescriptionHelpFormatterr(r:rZr_�	Namespacer�r�r�r��_SubParsersActionr�r�r�r�r�r�r�r�r�r�r�r�r�rr8r	r�boolr8rGrLrTr;r r!r"�<module>rps
��)�(�������������	�	�	�	�	�	�	�	�����
�
�
�
�������������������,�,�,�,�,�,�,�,�,�,�,�,�����B�B�B�B�B�B�B�B�-�-�-�-�-�-�����$�$�$�$�$�$�$�$�1�1�1�1�1�1�1�1�#�#�#�#�#�#�#�#�,�,�,�,�,�,�,�,�������+�+�+�+�+�+�8�8�8�8�8�8�8�8�8�8�8�8�#�#�#�#�#�#�$�$�$�$�$�$�	��	�8�	$�	$���#���S�	�)�*�
�����
�H�O��
�
�	�#�8�?�	�&)�S��)C�%D�%D�
	�	�%(�C�	�(?�$@�$@�	�	�	�����I�I����
�
�
�
���R�Y�9�>�J�J��%�h�o��(2;�1L�)��0"+�!?�1��8�9��� � ��F*�*�*�*�*�8�#G�*�*�*�	
�	
�	
�	
�	
�	
�	
�	
��d�3��8�n���c�������t�C��H�~��$�s�)�����B;�8�-�B;�(�B;�B;�B;�B;�J�h�5��$�����&�X�%<������� �X�7� �D� � � � �F5�M�5�d�5�5�5�5�>5�]�5�t�5�5�5�5�,5��!;�5��5�5�5�5�*5�}�5��5�5�5�5�5�8�#=�5�$�5�5�5�5�5�}�5��5�5�5�5�65�8�#=�5�$�5�5�5�5�:5�(�4�5��5�5�5�5�&64��3�64��64�64�64�64�r5�M�5�d�5�5�5�5�&�� :��t�����4��!;�������*$�H�3�$�$�$�$�N�$�t�*��3��4�����������().�4�).�D�).�).�).�).�X*
��"�*
�t�*
�*
�*
�*
�Z��!3��������X�����6�z����C�H�S�S�U�U�O�O�O�O�O��r!

Youez - 2016 - github.com/yon3zu
LinuXploit