Documentation ¶
Overview ¶
Package util contains various u-root utility functions.
Index ¶
Constants ¶
View Source
const ( // Not all these paths may be populated or even exist but OTOH they might. PATHHEAD = "/ubin" PATHMID = "/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/bin:/usr/local/sbin" PATHTAIL = "/buildbin:/bbin" )
Variables ¶
View Source
var (
Env = map[string]string{
"LD_LIBRARY_PATH": "/usr/local/lib",
"GOROOT": "/go",
"GOPATH": "/",
"GOBIN": "/ubin",
"CGO_ENABLED": "0",
}
)
Functions ¶
func UrootPath ¶
UrootPath returns the full path for a uroot file with the UROOT_ROOT environment variable taken into account. It returns a proper value if UROOT_ROOT is not set. u-root was built to assume everything is rooted at /, and in most cases that is still true. But in hosted mode, e.g. on developer mode chromebooks, it's far better if u-root can be rooted in /usr/local, so successive kernel/root file system upgrades do not wipe it out.
Types ¶
Click to show internal directories.
Click to hide internal directories.