1 KiB
1 KiB
coreutil
Import: dappco.re/go/core/container/internal/coreutil
Files: 1
Types
Functions
Exported Functions
DirSep() string: Returns the active directory separator, preferring theDSenvironment variable and otherwise/.JoinPath(parts ...string) string: Joins path elements withDirSep()and normalizes the result withcore.CleanPath.HomeDir() string: Returns the home directory by checkingCORE_HOME,HOME,USERPROFILE, and thenDIR_HOME.CurrentDir() string: Returns the current working directory fromPWD, orDIR_CWDwhenPWDis unset.TempDir() string: Returns the temporary directory fromTMPDIR, orDIR_TMPwhenTMPDIRis unset.AbsPath(path string) string: ReturnsCurrentDir()for an empty string, preserves absolute paths, and otherwise resolves relative paths against the current directory.MkdirTemp(prefix string) (string, error): Creates a deterministic temporary directory insideTempDir()using the supplied prefix ortmp-when no prefix is provided.