Documentation
¶
Index ¶
- func AppendText(path, appendStr string, perm os.FileMode) error
- func Contains(filename, findStr string) (bool, error)
- func Exist(path string) bool
- func GetGoSrcPath() (string, error)
- func GetPaths(dir string, includeDir bool, matchingPatterns ...string) (matches []string, e error)
- func GetPathsRecurcive(dir string, includeDir bool, matchingPatterns ...string) (paths []string, e error)
- func IsDir(path string) (bool, error)
- func ReplaceText(filename, origin, replace string, perm os.FileMode) error
- func WriteText(path, str string, createIfNothing bool, perm os.FileMode) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppendText ¶
AppendText apeend appendStr at the end of the file perm is permittion. exsample 0777.
func GetPaths ¶
GetPaths get files (and directory if includeDir=true) that match patterns
matchingPatterns exsample "*.go","*.yaml" if you want all , "*"
func GetPathsRecurcive ¶
func GetPathsRecurcive(dir string, includeDir bool, matchingPatterns ...string) (paths []string, e error)
GetPathsRecurcive recursively find and get files (and directory if includeDir=true) that match patterns recurcive.
matchingPatterns exsample "*.go","*.yaml" if you want all , "*"
func ReplaceText ¶
ReplaceText replace originStr to replaceStr perm is permittion. exsample 0777.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.