TheDiscordian/ipfs-sync

"Add to parent" type feature

TheDiscordian opened this issue · 3 comments

Rome Silvanus in a chat room has asked for a feature like so:

Upon adding a directory, add it to the parent in MFS, not just the root. So /home/user/dir1/dir2, when added, would create a dir in mfs like /ipfs-sync/dir1/dir2, but ONLY sync dir2's data, retaining dir1 as the parent directory. This way people can simply do things like adding select directories out of something like Google Drive, and having the same tree accessible, with non-shared directories omitted.

Currently this can be solved with symlinks on the FS itself. Is there any interest in this feature?

AddToParent could be the flag added for each dir that wants to be added to the parent dir in MFS.

For this feature to be stable, it should expect users to enable/disable this after sync, so we'll need to ensure the MFS is setup correctly upon change.

I want to add to this. My main motivation is to be able to add one big folder, basically in chunks, by adding the individual subfolders in the config file.
This way ipfs-sync can finish adding one folder after the other and it will be reachable over IPFS without the need to wait hash over the whole big root directory first.

It'll still take ages for my data set, but at least it's faster than the alternative.