You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm having an issue using the get command to recursively copy a directory, its subdirs, and included files from a Github repo to local. Although fsspec finds all of the files, with their correct path and lists them with find, when running get, it creates the relevant subdirs, but then copies the files to the parent directory.
Where the subdirs (execute-results, figure-html, figure-pdf) are created, but left empty, and what should have been put in them are just copied into the main directory.
Is this a bug, or should I be doing something else to make sure the files are placed in the correct subdirectories?
The text was updated successfully, but these errors were encountered:
This is functioning correctly, with behaviour copied from command-line cp. If you supply a list of concrete paths (files), then they will all appear in the target directory at the root level.
To copy the directory tree, supply the root path name with recursive, and fsspec will find all the paths for you:
Ah, thank you! Both of your suggestions were very helpful. I think I was including the fs.ls(...) because that was included in the original suggestion I saw to use fsspec. The documentation for .get confused me a bit for how to include the path, but of course it's very simple!
But yes, as you said, directly using git was much faster.
Thanks for the package, it's very helpful!
I'm having an issue using the get command to recursively copy a directory, its subdirs, and included files from a Github repo to local. Although fsspec finds all of the files, with their correct path and lists them with
find
, when runningget
, it creates the relevant subdirs, but then copies the files to the parent directory.I'm trying to copy the contents and structure of this folder from Github to a local folder: https://github.com/MitchellAcoustics/JASAEL-HowToAnalyseQuantiativeSoundscapeData/tree/main/_freeze/paper
Running:
finds everything just fine
But running
get
:results in this:
Where the subdirs (execute-results, figure-html, figure-pdf) are created, but left empty, and what should have been put in them are just copied into the main directory.
Is this a bug, or should I be doing something else to make sure the files are placed in the correct subdirectories?
The text was updated successfully, but these errors were encountered: