#include "lix/libutil/types.hh"
#include <sys/types.h>
Go to the source code of this file.
◆ createNixStateDir()
| Path nix::createNixStateDir |
( |
| ) |
|
Create $XDG_STATE_HOME/nix or $HOME/.local/state/nix, and return the path to it.
- Note
- Not to be confused with settings.nixStateDir.
◆ expandTilde()
| std::string nix::expandTilde |
( |
std::string_view | path | ) |
|
Perform tilde expansion on a path.
◆ getCacheDir()
| Path nix::getCacheDir |
( |
| ) |
|
- Returns
- $XDG_CACHE_HOME or $HOME/.cache.
◆ getConfigDir()
| Path nix::getConfigDir |
( |
| ) |
|
- Returns
- $XDG_CONFIG_HOME or $HOME/.config.
◆ getConfigDirs()
| std::vector< Path > nix::getConfigDirs |
( |
| ) |
|
- Returns
- the directories to search for user configuration files
◆ getDataDir()
- Returns
- $XDG_DATA_HOME or $HOME/.local/share.
◆ getHome()
- Returns
- $HOME or the user's home directory from /etc/passwd.
◆ getHomeOf()
| Path nix::getHomeOf |
( |
uid_t | userId | ) |
|
- Returns
- the given user's home directory from /etc/passwd.
◆ getStateDir()
| Path nix::getStateDir |
( |
| ) |
|
- Returns
- $XDG_STATE_HOME or $HOME/.local/state.
- Note
- Not to be confused with settings.nixStateDir.