HEX
Server: LiteSpeed
System: Linux s1049.use1.mysecurecloudhost.com 4.18.0-477.27.2.lve.el8.x86_64 #1 SMP Wed Oct 11 12:32:56 UTC 2023 x86_64
User: xedaptot (3356)
PHP: 8.3.31
Disabled: NONE
Upload Files
File: //usr/local/lib/python3.6/site-packages/ptyprocess/__pycache__/util.cpython-36.pyc
3

��Zd�
�@s`yddlmZWn:ek
rJddlZddlZejejBdfdd�ZYnXGdd�de�ZdS)�)�whichNcs"dd�}tjj��r&|�|�r"�SdS|dkr>tjjdtj�}|sFdS|jtj�}tj	dkr�tj
|krt|jdtj
�tjjdd�jtj�}t�fd	d
�|D��r��g}q‡fdd�|D�}n�g}t
�}xT|D]L}tjj|�}||kr�|j|�x(|D] }	tjj||	�}
||
|�r�|
Sq�Wq�WdS)
aSGiven a command, mode, and a PATH string, return the path which
        conforms to the given mode on the PATH, or None if there is no such
        file.
    
        `mode` defaults to os.F_OK | os.X_OK. `path` defaults to the result
        of os.environ.get("PATH"), or can be overridden with a custom search
        path.
    
        cSs&tjj|�o$tj||�o$tjj|�S)N)�os�path�exists�access�isdir)�fn�mode�r
�5/tmp/pip-build-hc5bmb4z/ptyprocess/ptyprocess/util.py�
_access_checkszwhich.<locals>._access_checkN�PATH�win32r�PATHEXT�c3s |]}�j�j|j��VqdS)N)�lower�endswith)�.0�ext)�cmdr
r�	<genexpr>1szwhich.<locals>.<genexpr>csg|]}�|�qSr
r
)rr)rr
r�
<listcomp>4szwhich.<locals>.<listcomp>)rr�dirname�environ�get�defpath�split�pathsep�sys�platform�curdir�insert�any�set�normcase�add�join)rr	rr�pathext�files�seen�dir�normdir�thefile�namer
)rrrs8







rc@seZdZdZdS)�PtyProcessErrorz%Generic error class for this package.N)�__name__�
__module__�__qualname__�__doc__r
r
r
rr.Fsr.)	�shutilr�ImportErrorrr�F_OK�X_OK�	Exceptionr.r
r
r
r�<module>s
?