Subject: Re: [PATCH v2 3/5] repo_read_index: clear SKIP_WORKTREE bit from files present in worktree

From: Jonathan Nieder <[email-masked]>
Date: Tue, 22 Feb 2022 15:17:00 -0800

Hi,

Derrick Stolee wrote:

> Just chiming in here to say that we've dealt with these issues in
> microsoft/git by special-casing them behind our core_virtualfilesystem
> global. A recent example is the changes to 'git add' to prevent
> adding a file that is marked as sparse (unless --sparse is specified).
> We always allow this when in the virtualized scenario [1].
>
> [1] https://github.com/microsoft/git/blob/2f6531aced2e77a6c1000a923967ae0105383930/builtin/add.c#L50-L54

Oh!  Thanks for that pointer --- it's very helpful.  I hadn't realized
that VFS for Git still requires a patched Git.

> This seems like something that should be on vfsd to handle, and should
> not prevent upstream Git from making changes that benefit its users.

Separate from the "should" questions (in general I'm in favor of
unpatched Git being able to serve as a solid platform for both Scalar
and this kind of VFS use case), this context tells me that this is not
in fact a regression for VFS for Git users, so it's much appreciated.

Thanks,
Jonathan