Sindbad~EG File Manager
�
4Μg�) � � � d Z ddlmZ ddlZddlZddlmZ ddlmZ ddl m
Z
mZ ddlm
Z
ej d k( rdd
�ZnddlmZ G d� d
e
� Zdd�Zdd�Zd
gZy)zUnix.� )�annotationsN)�ConfigParser)�Path)�Iterator�NoReturn� )�PlatformDirsABC�win32c � � d} t | � �)Nzshould only be used on Unix)�RuntimeError)�msgs �H/usr/local/lib/python3.12/site-packages/pip/_vendor/platformdirs/unix.py�getuidr s � �+���3��� )r c � � e Zd ZdZedd�� Zedd�� Zedd�� Zedd�� Zedd�� Z edd�� Z
edd�� Zedd �� Zedd
�� Z
edd�� Zedd�� Zedd
�� Zedd�� Zedd�� Zedd�� Zedd�� Zedd�� Zedd�� Zedd�� Zedd�� Zedd�� Zdd�Zdd�Zdd�Zy) �Unixa�
On Unix/Linux, we follow the `XDG Basedir Spec <https://specifications.freedesktop.org/basedir-spec/basedir-spec-
latest.html>`_.
The spec allows overriding directories with environment variables. The examples shown are the default values,
alongside the name of the environment variable that overrides them. Makes use of the `appname
<platformdirs.api.PlatformDirsABC.appname>`, `version <platformdirs.api.PlatformDirsABC.version>`, `multipath
<platformdirs.api.PlatformDirsABC.multipath>`, `opinion <platformdirs.api.PlatformDirsABC.opinion>`, `ensure_exists
<platformdirs.api.PlatformDirsABC.ensure_exists>`.
c �� � t j j dd� }|j � st j j d� }| j
|� S )z�
:return: data directory tied to the user, e.g. ``~/.local/share/$appname/$version`` or
``$XDG_DATA_HOME/$appname/$version``
�
XDG_DATA_HOME� z~/.local/share��os�environ�get�strip�path�
expanduser�_append_app_name_and_version��selfr s r �
user_data_dirzUnix.user_data_dir$ sG � � �z�z�~�~�o�r�2���z�z�|��7�7�%�%�&6�7�D��0�0��6�6r c � � t j j dd� }|j � sdt j � d�}|j t j � D �cg c] }| j
|� �� c}S c c}w )N�
XDG_DATA_DIRSr z/usr/local/sharez
/usr/share)r r r r �pathsep�splitr �r r �ps r �_site_data_dirszUnix._site_data_dirs/ sc � ��z�z�~�~�o�r�2���z�z�|�%�b�j�j�\��<�D�>B�j�j����>T�U�>T���1�1�!�4�>T�U�U��Us �&Bc �z � | j }| j s|d S t j j |� S )aZ
:return: data directories shared by users (if `multipath <platformdirs.api.PlatformDirsABC.multipath>` is
enabled and ``XDG_DATA_DIRS`` is set and a multi path the response is also a multi path separated by the
OS path separator), e.g. ``/usr/local/share/$appname/$version`` or ``/usr/share/$appname/$version``
r )r'