sympath

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsSymlink(fi os.FileInfo) bool

IsSymlink is used to determine if the fileinfo is a symbolic link.

func Walk

func Walk(root string, walkFn AbsWalkFunc) error

Walk walks the file tree rooted at root, calling walkFn for each file or directory in the tree, including root. All errors that arise visiting files and directories are filtered by walkFn. The files are walked in lexical order, which makes the output deterministic but means that for very large directories Walk can be inefficient. Walk follows symbolic links.

Types

type AbsWalkFunc

type AbsWalkFunc func(path, absPath string, info fs.FileInfo, err error) error

AbsWalkFunc functions like filepath.WalkFunc but provides the absolute path of fs.FileInfo when path is a symlink.

Jump to

Keyboard shortcuts

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