package homedir
import "github.com/docker/docker/pkg/homedir"
Index ¶
- func Get() string
- func GetConfigHome() (string, error)
- func GetDataHome() (string, error)
- func GetLibHome() (string, error)
- func GetRuntimeDir() (string, error)
- func GetShortcutString() string
- func Key() string
- func StickRuntimeDirContents(files []string) ([]string, error)
Functions ¶
func Get ¶
func Get() string
Get returns the home directory of the current user with the help of environment variables depending on the target operating system. Returned path should be used with "path/filepath" to form new paths.
If linking statically with cgo enabled against glibc, ensure the osusergo build tag is used.
If needing to do nss lookups, do not disable cgo or set osusergo.
func GetConfigHome ¶
GetConfigHome is unsupported on non-linux system.
func GetDataHome ¶
GetDataHome is unsupported on non-linux system.
func GetLibHome ¶
GetLibHome is unsupported on non-linux system.
func GetRuntimeDir ¶
GetRuntimeDir is unsupported on non-linux system.
func GetShortcutString ¶
func GetShortcutString() string
GetShortcutString returns the string that is shortcut to user's home directory in the native shell of the platform running on.
func Key ¶
func Key() string
Key returns the env var name for the user's home dir based on the platform being run on
func StickRuntimeDirContents ¶
StickRuntimeDirContents is unsupported on non-linux system.
Source Files ¶
homedir_others.go homedir_unix.go
- Version
- v23.0.3+incompatible
- Published
- Apr 4, 2023
- Platform
- js/wasm
- Imports
- 3 packages
- Last checked
- 1 hour ago –
Tools for package owners.