Documentation ¶
Overview ¶
Package path implements path related functions.
Index ¶
- Constants
- func Abs(name string) (string, error)
- func AbsJoin(dir, name string) (string, error)
- func Exist(name string) bool
- func ExpendHome(name string) (string, error)
- func FindGitWorkSpace(dir string) (string, string, error)
- func FindTopDir(dir string) (string, error)
- func HomeDir() (string, error)
- func IsDir(name string) bool
- func IsFile(name string) bool
- func IsGitDir(dir string) bool
- func SafeCreateParentDir(name string)
- func SetHome(home string)
- func UnsetHome()
Constants ¶
View Source
const (
// DotRepo is ".repo".
DotRepo = ".repo"
)
Macros for path
Variables ¶
This section is empty.
Functions ¶
func ExpendHome ¶
ExpendHome expends path prefix "~/" to home dir.
func FindGitWorkSpace ¶
FindGitWorkSpace walks to upper directories to find gitdir and worktree.
func FindTopDir ¶
FindTopDir finds repo root path, where has a '.repo' subdir.
func SafeCreateParentDir ¶
func SafeCreateParentDir(name string)
SafeCreateParentDir will create parent dir if not exist.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.