fsutil

package
v0.15.2 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2018 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyFile

func CopyFile(dst string, src string, excl map[string]bool) error

CopyFile is a braindead simple function that copies a src file to a dst file. Note that it is not general purpose: it doesn't handle symbolic links, it doesn't try to be efficient, it doesn't handle copies where src and dst overlap, and it makes no attempt to preserve file permissions. It is what we need for this utility package, no more, no less.

func QnamePath

func QnamePath(nm tokens.QName) string

QnamePath just cleans a name and makes sure it's appropriate to use as a path.

func WalkUp

func WalkUp(path string, walkFn func(string) bool, visitParentFn func(string) bool) (string, error)

WalkUp walks each file in path, passing the full path to `walkFn`. If walkFn returns true, this method returns the path that was passed to walkFn. Before visiting the parent directory, visitParentFn is called, if that returns false, WalkUp stops its search

Types

This section is empty.

Jump to

Keyboard shortcuts

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