Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MkdirAll is not respecting opts.FS #153

Open
nianyush opened this issue Jun 18, 2024 · 4 comments
Open

MkdirAll is not respecting opts.FS #153

nianyush opened this issue Jun 18, 2024 · 4 comments

Comments

@nianyush
Copy link

copy/copy.go

Line 104 in e40f4e6

if err = os.MkdirAll(filepath.Dir(dest), os.ModePerm); err != nil {

@nianyush nianyush changed the title Mkdir is not respecting opts.FS MkdirAll is not respecting opts.FS Jun 18, 2024
@nianyush
Copy link
Author

probably should use an alterantive MkdirAll that is compatible with fs.FS like https://github.com/twpayne/go-vfs/blob/master/mkdirall.go#L16

@otiai10
Copy link
Owner

otiai10 commented Jun 19, 2024

Thank you for your comment. Could you please create a test case that demonstrates the failure you described?

mafredri added a commit to mafredri/copy that referenced this issue Aug 20, 2024
This commit adds tests to reproduce otiai10#153.
@mafredri
Copy link

mafredri commented Aug 20, 2024

Not sure if this is the use-case @nianyush was referring to, but I created a PR #162 with some tests that don't work to illustrate the problem.

@nianyush
Copy link
Author

yes, i think your pr exactly describes what i was facing earlier @mafredri

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants