fsutil

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2021 License: MIT Imports: 4 Imported by: 2

Documentation

Overview

Package fsutil is common file system utils for Go.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanDir

func CleanDir(fpath string) error

CleanDir removes all children contained in the given path.

func Copy

func Copy(src, dst string) error

Copy copies a file or directory from src to dst.

func CopyFile

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

CopyFile copies a file from src to dst.

func HomeDir

func HomeDir() string

HomeDir returns the current user's home directory.

func IsDir

func IsDir(fpath string) bool

IsDir reports whether the given path is a directory.

func IsExists

func IsExists(fpath string) bool

IsExists reports whether the given path exists.

func IsSymlink(fpath string) bool

IsSymlink reports whether the given path is a symbolic link.

func Owner

func Owner(fpath string) (uid, gid int, err error)

Owner returns the uid and gid of the given path.

Types

This section is empty.

Jump to

Keyboard shortcuts

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