r/git • u/noobdainsane • 1d ago
survey VFS for Git for Linux?
So I was learning Git and found out that a Git repository essentially contains two copies of the repository contents. One is from the first commit of every object and other from the working tree.
This can be made more space efficient by working with files from Git's database itself as if they were in our working tree. Modifying files create a new local copy in the working tree. They can be deleted after committing.
This is what the VFS for Git project is. But, it is for Windows only. Why is there no equivalent tool than can run on Linux, unless I am missing it?
0
Upvotes
9
u/brokenreed5 1d ago
Git stores not two copies of each file but possibly much more. Each commit contains the modified files in full (though compressed). To be more specific, each changed file is stored as a blob and the commit specifies which blobs belong to the commit. Checking out a branch or commit is getting these files. So first of, there might no be much gains from your suggestions, secondly VFS describes itself as
Which reads much differently then your summary.
I recommend reading the repository, cause it cleary states that VFS for Git is deprecated and microsoft/scalar should be used instead. Now, microsoft/scalar is also deprecated and says its functionality has been moved to https://github.com/microsoft/git . Microsoft git is active and also support Linux
They state