filesystem

package
v1.7.1 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyFile

func CopyFile(src, dst string) (err error)

CopyFile copies a file from src to dst. If src and dst files exist, and are the same, then return successfully. Otherise, attempt to copy the file contents from src to dst. The file will be created if it does not already exist. If the destination file exists, all it's contents will be replaced by the contents of the source file.

func FileExists

func FileExists(path string) bool

FileExists asserts whether a file path exists.

func MakeDirectoryIfNotExists

func MakeDirectoryIfNotExists(path string) error

MakeDirectoryIfNotExists asserts whether a directory exists and makes it if not. Returns nil if exists or successfully made.

Types

This section is empty.

Jump to

Keyboard shortcuts

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