Temporary git files for the gitdir created on a separate drive in workdir
- Date: Fri, 7 Sep 2018 08:24:01 +0200
- From: Hultqvist <hultqvist@xxxxxxxxxxxxxxx>
- Subject: Temporary git files for the gitdir created on a separate drive in workdir
I'm having two types of git repos in separate drives, in this case G:
is a Google Drive File Stream meaning a slow synchronized storage.
G:\Test1\.git containing "gitdir: C:\Test1.git"
In the first repo I see a lot of "master", "config" and "index" files
being created in the root of the workdir.
The nature of the slow sync causes these files to duplicate - not gits fault.
In the second repo no artefacts are noticed.
I understand that the files are first created "somewhere else" to make
an atomic move later.
In the first repo, the nature of being two separate drives appear to
cause the residue.
In the second repo it works right.
Considering that the gitdir could be located on a different drive than
the workdir wouldn't it make more sense to create the temporary files
in a subdirectory inside the gitdir rather tan in the workdir?
Are there any flags or environment variables to control where
temporary files are created?