
    ?wg                    L    d Z ddlmZ ddlZddlZddlmZ  G d de      ZdgZ	y)zmacOS.    )annotationsN   )PlatformDirsABCc                  0   e Zd ZdZedd       Zedd       Zedd       Zedd       Zedd       Z	edd       Z
edd       Zedd	       Zedd
       Zedd       Zedd       Zedd       Zedd       Zedd       Zedd       Zedd       Zy)MacOSa  
    Platform directories for the macOS operating system.

    Follows the guidance from
    `Apple documentation <https://developer.apple.com/library/archive/documentation/FileManagement/Conceptual/FileSystemProgrammingGuide/MacOSXDirectories/MacOSXDirectories.html>`_.
    Makes use of the `appname <platformdirs.api.PlatformDirsABC.appname>`,
    `version <platformdirs.api.PlatformDirsABC.version>`,
    `ensure_exists <platformdirs.api.PlatformDirsABC.ensure_exists>`.

    c                ^    | j                  t        j                  j                  d            S )zb:return: data directory tied to the user, e.g. ``~/Library/Application Support/$appname/$version``z~/Library/Application Support_append_app_name_and_versionospath
expanduserselfs    \/var/www/horilla/myenv/lib/python3.12/site-packages/setuptools/_vendor/platformdirs/macos.pyuser_data_dirzMacOS.user_data_dir   s%     001C1CDc1dee    c                   t         j                  j                  d      }|r| j                  d      gng }|j	                  | j                  d             | j
                  rt        j                  j                  |      S |d   S )aB  
        :return: data directory shared by users, e.g. ``/Library/Application Support/$appname/$version``.
          If we're using a Python binary managed by `Homebrew <https://brew.sh>`_, the directory
          will be under the Homebrew prefix, e.g. ``/opt/homebrew/share/$appname/$version``.
          If `multipath <platformdirs.api.PlatformDirsABC.multipath>` is enabled, and we're in Homebrew,
          the response is a multi-path string separated by ":", e.g.
          ``/opt/homebrew/share/$appname/$version:/Library/Application Support/$appname/$version``
        /opt/homebrewz/opt/homebrew/sharez/Library/Application Supportr   	sysprefix
startswithr
   append	multipathr   pathsepjoinr   is_homebrew	path_lists      r   site_data_dirzMacOS.site_data_dir   so     jj++O<R]T667LMNce	::;YZ[>>::??9--|r   c                    | j                   S )zC:return: config directory tied to the user, same as `user_data_dir`r   r   s    r   user_config_dirzMacOS.user_config_dir-        !!!r   c                    | j                   S )zF:return: config directory shared by the users, same as `site_data_dir`)r    r   s    r   site_config_dirzMacOS.site_config_dir2   r$   r   c                ^    | j                  t        j                  j                  d            S )zV:return: cache directory tied to the user, e.g. ``~/Library/Caches/$appname/$version``z~/Library/Cachesr	   r   s    r   user_cache_dirzMacOS.user_cache_dir7   s%     001C1CDV1WXXr   c                   t         j                  j                  d      }|r| j                  d      gng }|j	                  | j                  d             | j
                  rt        j                  j                  |      S |d   S )a1  
        :return: cache directory shared by users, e.g. ``/Library/Caches/$appname/$version``.
          If we're using a Python binary managed by `Homebrew <https://brew.sh>`_, the directory
          will be under the Homebrew prefix, e.g. ``/opt/homebrew/var/cache/$appname/$version``.
          If `multipath <platformdirs.api.PlatformDirsABC.multipath>` is enabled, and we're in Homebrew,
          the response is a multi-path string separated by ":", e.g.
          ``/opt/homebrew/var/cache/$appname/$version:/Library/Caches/$appname/$version``
        r   z/opt/homebrew/var/cachez/Library/Cachesr   r   r   s      r   site_cache_dirzMacOS.site_cache_dir<   so     jj++O<VaT667PQRgi	::;LMN>>::??9--|r   c                    | j                   S )zB:return: state directory tied to the user, same as `user_data_dir`r"   r   s    r   user_state_dirzMacOS.user_state_dirM   r$   r   c                ^    | j                  t        j                  j                  d            S )zR:return: log directory tied to the user, e.g. ``~/Library/Logs/$appname/$version``z~/Library/Logsr	   r   s    r   user_log_dirzMacOS.user_log_dirR   s%     001C1CDT1UVVr   c                @    t         j                  j                  d      S )zC:return: documents directory tied to the user, e.g. ``~/Documents``z~/Documentsr   r   r   r   s    r   user_documents_dirzMacOS.user_documents_dirW        ww!!-00r   c                @    t         j                  j                  d      S )zC:return: downloads directory tied to the user, e.g. ``~/Downloads``z~/Downloadsr0   r   s    r   user_downloads_dirzMacOS.user_downloads_dir\   r2   r   c                @    t         j                  j                  d      S )zA:return: pictures directory tied to the user, e.g. ``~/Pictures``z
~/Picturesr0   r   s    r   user_pictures_dirzMacOS.user_pictures_dira   s     ww!!,//r   c                @    t         j                  j                  d      S )z=:return: videos directory tied to the user, e.g. ``~/Movies``z~/Moviesr0   r   s    r   user_videos_dirzMacOS.user_videos_dirf   s     ww!!*--r   c                @    t         j                  j                  d      S )z;:return: music directory tied to the user, e.g. ``~/Music``z~/Musicr0   r   s    r   user_music_dirzMacOS.user_music_dirk   s     ww!!),,r   c                @    t         j                  j                  d      S )z?:return: desktop directory tied to the user, e.g. ``~/Desktop``z	~/Desktopr0   r   s    r   user_desktop_dirzMacOS.user_desktop_dirp   s     ww!!+..r   c                ^    | j                  t        j                  j                  d            S )zg:return: runtime directory tied to the user, e.g. ``~/Library/Caches/TemporaryItems/$appname/$version``z~/Library/Caches/TemporaryItemsr	   r   s    r   user_runtime_dirzMacOS.user_runtime_diru   s%     001C1CDe1fggr   c                    | j                   S )zF:return: runtime directory shared by users, same as `user_runtime_dir`)r>   r   s    r   site_runtime_dirzMacOS.site_runtime_dirz   s     $$$r   N)returnstr)__name__
__module____qualname____doc__propertyr   r    r#   r&   r(   r*   r,   r.   r1   r4   r6   r8   r:   r<   r>   r@    r   r   r   r      sO   	 f f    " " " " Y Y    " " W W 1 1 1 1 0 0 . . - - / / h h % %r   r   )
rF   
__future__r   os.pathr   r   apir   r   __all__rH   r   r   <module>rM      s/     "  
  r%O r%l r   