Helpers for $HOME directory.
More...
#include <HomeDir.h>
|
| static std::filesystem::path | get () noexcept |
| | Obtains home directory.
|
| static std::filesystem::path | getCacheDir () noexcept |
| | Obtains directory for caching.
|
| static std::filesystem::path | createCacheDir (const std::filesystem::path &subdir) noexcept |
| | Creates (if not existing) and returns getCacheDir() / subdir.
|
Helpers for $HOME directory.
◆ createCacheDir()
| std::filesystem::path SlHelpers::HomeDir::createCacheDir |
( |
const std::filesystem::path & | subdir | ) |
|
|
inlinestaticnoexcept |
Creates (if not existing) and returns getCacheDir() / subdir.
- Parameters
-
| subdir | Subdirectory to append to cache dir |
- Returns
- Created getCacheDir() /
subdir.
◆ get()
| std::filesystem::path SlHelpers::HomeDir::get |
( |
| ) |
|
|
inlinestaticnoexcept |
Obtains home directory.
- Returns
- $HOME or /etc/passwd home entry.
◆ getCacheDir()
| std::filesystem::path SlHelpers::HomeDir::getCacheDir |
( |
| ) |
|
|
inlinestaticnoexcept |
Obtains directory for caching.
- Returns
- $XDG_CACHE_HOME or $HOME/.cache.
The documentation for this class was generated from the following file:
- /home/abuild/rpmbuild/BUILD/slhelpers-20260428.f233ce9-build/slhelpers-20260428.f233ce9/include/helpers/HomeDir.h