Documentation ¶
Index ¶
- func ChangeFileTime(dstFile, srcFile string) error
- func ClearFile(fp string) error
- func CopyFile(src, dst string) error
- func CountFile(fp string) (int, error)
- func CreateDir(d string) error
- func ExecScript(script string) ([]byte, error)
- func ExecScriptBG(script string) error
- func GetHomeDir() (string, error)
- func IsDir(fp string) bool
- func IsFile(path string) bool
- func IsFileExists(fp string) bool
- func IsProcessExisted(name string) bool
- func IsStrInArr(s string, arr []string) bool
- func KillProcess(name string, force bool) error
- func RandomPasswd(length int) string
- func ReadFileLines(fp string) ([]string, error)
- func RemoveDuplicatedArrs(arr1, arr2 []string) []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ChangeFileTime ¶ added in v0.4.0
修改文件的三个时间:将 srcFile 的时间修改为 dstFile 的时间
func IsStrInArr ¶ added in v0.4.0
IsStrInArr 判断数组 arr 中是否包含 s 元素
func RandomPasswd ¶ added in v0.4.0
func ReadFileLines ¶ added in v0.4.0
ReadFileLines 读取文件所有行,适合文件不是特别大的场景
func RemoveDuplicatedArrs ¶ added in v0.4.0
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.