blob: 4053a3fd5de2a676da02f9d21bc167aa70098714 [file] [log] [blame]
package copy
// Options specifies optional actions on copying.
type Options struct {
// OnSymlink can specify what to do on symlink
OnSymlink func(p string) SymlinkAction
// SymlinkAction represents what to do on symlink.
type SymlinkAction int
const (
// Deep creates hard-copy of contents.
Deep SymlinkAction = iota
// Shallow creates new symlink to the dest of symlink.
// Skip does nothing with symlink.
// DefaultOptions by default.
var DefaultOptions = Options{
OnSymlink: func(string) SymlinkAction {
return Shallow