file

package
v1.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 3, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DirSize added in v1.1.0

func DirSize(dirName string) (int64, error)

DirSize directory size bytes

func Dump

func Dump(fileName string, content []byte) error

Dump content 2 file

func Exists

func Exists(path string) bool

Exists check path exists

func IsDir

func IsDir(path string) bool

IsDir check path is directory

func IsFile

func IsFile(path string) bool

IsFile check path is file

func List

func List(dirName string) ([]os.FileInfo, error)

List dir

func Load

func Load(fileName string) ([]byte, error)

Load file content

func Mkdir

func Mkdir(dirName string, perm os.FileMode) error

Mkdir make dir

func Remove

func Remove(fileName string) error

Remove file

func Touch

func Touch(fileName string, perm os.FileMode) error

Touch empty file

func WriteFile

func WriteFile(fileName, content string, perm os.FileMode) error

WriteFile write file

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL