Documentation
¶
Overview ¶
Package sysutil is common system utils for Go.
Index ¶
- func EnvOr(key, def string) string
- func FQDN() (string, error)
- func GetProcessByPid(pid int) string
- func HomeDir() (home string)
- func IsBigEndian() bool
- func IsLinux() bool
- func IsWindows() bool
- func Kill(pid int) error
- func PID() int
- func Pwd() (home string)
- func TmpDir() string
- func User() *user.User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnvOr ¶ added in v0.2.0
EnvOr retrieves the value of the environment variable named by the key. If the variable is present in the environment the value (which may be empty) is returned. Otherwise, the default value will be returned.
func GetProcessByPid ¶
GetProcessByPid Get process with the given PID
func IsBigEndian ¶
func IsBigEndian() bool
IsBigEndian reports whether current os byte order is big endian.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.