otiai10 / copy

Go copy directory recursively

Home Page:https://pkg.go.dev/github.com/otiai10/copy

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How does this differ from https://github.com/golang/dep/blob/v0.5.4/internal/fs/fs.go#L175

quackduck opened this issue · comments

Have a look at: https://github.com/golang/dep/blob/v0.5.4/internal/fs/fs.go#L175

How different are copy.Copy() and renameByCopy()?

As far as I understand it,

  • copy.Copy handles more types of file entries, such as symlinks.
  • copy.Copy can add permissions (and ownership coming soon) of destination files.
  • fs. renameByCopy removes all source files copied (the thing you should compare with is fs.CopyDir, just I guess).
  • copy.Copy provides some additional options.
  • more than all, dep/internal/fs is internal and dep is deprecated.

Let me know your thought.

@quackduck I will close this issue if no any reply

Sorry, I forgot to say: Oh okay!