package
0.1.11
Repository: https://github.com/sllt/af.git
Documentation: pkg.go.dev

# Functions

ClearFile write empty string to path file.
CopyFile copy src file to dest file.
CreateDir create directory in absolute path.
CreateFile create a file in path.
CurrentPath return current absolute path.
FileMode return file's mode and permission.
FileSize returns file size in bytes.
IsDir checks if the path is directory or not.
IsExist checks if a file or directory exists.
IsLink checks if a file is symbol link or not.
IsZipFile checks if file is zip or not.
ListFileNames return all file names in the path.
MiMeType return file mime type param `file` should be string(file path) or *os.File.
MTime returns file modified time.
ReadCsvFile read file content into slice.
ReadFileByLine read file line by line.
ReadFileToString return string of file content.
RemoveFile remove the path file.
Sha returns file sha value, param `shaType` should be 1, 256 or 512.
UnZip unzip the file and save it to destPath.
WriteBytesToFile write bytes to target file.
WriteCsvFile write content to target csv file.
WriteStringToFile write string to target file.
Zip create zip file, fpath could be a single file or a directory.
ZipAppendEntry append a single file or directory by fpath to an existing zip file.