Closed Jjagg closed 7 years ago
The idea is to provide local git filesystem only, mainly to access the folders/files of a repository for a particular commit without having to check-out.
Currently, I don't have plans for anything related to remote providers. As you may have noticed, Zio doesn't provide an async API. The primary reason is that providing an API over remote/breakable connection requires a lot more extra care (like async, cancellation tokens...etc.) and could shape the API quite differently... and that would complicate usages for just plain local scenarios.
Thanks for that clarification! I'll close this since it's not relevant for the local Git FS you have in mind.
Hey @xoofx! When you wrote you'd like to "Add support for Git FileSystem (readonly)", did you mean mounting a remote without fetching all files? I looked into this a bit and it seems that's not very straightforward with Git. For one there is no way to get the directory tree from a remote without fetching the actual files. It's also not possible to fetch specific files from a remote. So I don't think a VFS for Git that lazily fetches files can be implemented. At least not for Git directly.
Microsoft recently open-sourced Git Virtual FileSystem (GVFS) which relies on additional operations - specified by their GVFS protocol - for its implementation. If the big Git services were to implement that protocol, implementing a VFS based on that is probably the best course of action.
Of course a VFS could also be implemented specifically for GitHub or any other service with a public API that supports the required operations. Short term, this is what I'd go for (I'm only interested in GitHub at this point).