Mystery c:\.git folder - solved

Many of us suffered from the annoyance of a .git folder keep popping up in the root folder - see for example the discussion below.

Good news: the mystery is now solved, it was due to a copy-paste error in a git hook file copying script. Pull request was submitted with a proposed fix.

From: Dženan Zukić [mailto:dzenanz@gmail.com]
Sent: Monday, July 25, 2016 11:38 AM
To: Andras Lasso lasso@queensu.ca
Subject: Re: [vtkusers] [ITK-dev] c:.git\hooks

Pain is smaller when I know that I am not the only one suffering :smiley:

On Mon, Jul 25, 2016 at 11:36 AM, Andras Lasso lasso@queensu.ca wrote:
I have the issue, too. Unfortunately, we almost work on the same projects (Plus , Slicer – with all its dependencies) so we still don’t know what can cause this.

Andras

From: vtkusers [mailto:vtkusers-bounces@vtk.org] On Behalf Of Dženan Zukic
Sent: July 25, 2016 11:32
To: Brad King brad.king@kitware.com
Cc: vtkusers vtkusers@vtk.org; ITK developer mailing list insight-developers@itk.org
Subject: Re: [vtkusers] [ITK-dev] c:.git\hooks

I ran all the SetupForDevelopment scripts in ITK git folder. The C:/.git folder was not created. Thanks for suggestion though.

This problem is not annoying enough because it is easy to solve by deleting C:/.git folder. I will not spend more time randomly examining everything git-related. If somebody else comes forward with the same problem then we might be able to determine what we have in common and narrow down the problem to perhaps make it reasonably tractable.

So if anyone runs into this, don’t be shy!

On Fri, Jul 22, 2016 at 9:14 AM, Brad King brad.king@kitware.com wrote:
On 07/22/2016 09:00 AM, Dženan Zukić wrote:

occasionally, a folder “C:.git\hooks” appears on my computer.
[snip]
but support people think that git hooks in some of my projects
(almost all instances of ITK, VTK and Slicer builds) are causing
this behavior. Did anyone else encounter this or something similar?

Dig through our Utilities/SetupForDevelopment.sh scripts (or equivalent
in each project) and the scripts it invokes. See if running any of
them causes this to happen. Otherwise check whether running CMake on
each project causes it in case there is any attempt to install hooks
that way.

You’ll likely have to diligently check for the folder after each step
of working with each project until you figure out which one causes it.

-Brad

2 Likes

Awesome! Thanks for figuring this out and submitting a patch!

Francois

1 Like

Great job tracking this down!

1 Like

I love you Andras! :heart:

1 Like