Documentation ¶
Index ¶
- func ArchAlias(arch string) string
- func CountDirFiles(dirName string) int
- func CreateDir(path string) error
- func FileMD5(path string) (string, error)
- func GetArgs(argsMap map[string]string, args []string) ([]string, map[string]string)
- func GetAvailableIP(ipAndMask string) []string
- func GetAvailableIPRange(ipStart, ipEnd string) []string
- func GetLocalIP() (string, error)
- func Home() (string, error)
- func IPAddressToCIDR(ipAddress string) string
- func IPMaskStringToCIDR(netmask string) string
- func IsDir(path string) bool
- func IsExist(path string) bool
- func LocalIP() string
- func LocalMd5Sum(src string) string
- func MkFileFullPathDir(fileName string) error
- func Mkdir(dirName string) error
- func ParseIp(ip string) []string
- func Render(tmpl *template.Template, variables map[string]interface{}) (string, error)
- func Round(val float64, precision int) float64
- func ShortDur(d time.Duration) string
- func Tar(src, dst, trimPrefix string) error
- func Untar(src, dst string) error
- func WriteFile(fileName string, content []byte) error
- type Data
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CountDirFiles ¶
func GetAvailableIP ¶
func GetAvailableIPRange ¶
func GetLocalIP ¶
func IPAddressToCIDR ¶
func IPMaskStringToCIDR ¶
func LocalMd5Sum ¶
func MkFileFullPathDir ¶
MkFileFullPathDir is used to file create the full path. eg. there is a file "./aa/bb/xxx.txt", and dir ./aa/bb is not exist, and will create the full path dir.
Types ¶
Click to show internal directories.
Click to hide internal directories.