Closed khatchad closed 5 years ago
I wonder if it's Eclipse.
It doesn't happen when I run N2O, I wonder if it's something to do with the way Logging uses the egit plugin?
.git
are hidden on windows. I did not notice it before. I can let the tool create a git repository, but the repo does not have any git history.
Can the tool create git repositories?
Seems like this only happens when subprojects are involved. My guess is that this is a situation where the project (subproject here) doesn't have a git repo because it's part of a part that does have a git repo, and this somehow leads to the creating of the fake embedded repo.
Seems like this only happens when subprojects are involved. My guess is that this is a situation where the project (subproject here) doesn't have a git repo because it's part of a part that does have a git repo, and this somehow leads to the creating of the fake embedded repo
You are right.
The reason that the folder could be in the top-level directory is that the tool also recursively searches the repository file. If it cannot find a repo, it will return the top-level directory and initialize a repo for it.
Most of these projects have subprojects and we can't have git submodules randomly around.
I have two ideas to fix it.
Option 1: I could let the tool only search the parent file. The tool will not recursively search the top-level file.
Option 2: let the tool recursively search the top-level file until it reaches the workspace directory.
Both of them may miss some projects. Which way do you think it is better?
To be clear, the behavior should stay the same except for the .git
directories being created in sub-projects. Everything else remains the same.
To be clear, the behavior should stay the same except for the .git directories being created in sub-projects. Everything else remains the same.
I see. I should find a solution to let the tool initialize the repo only if the directory is a repo.
I tested selenium and the .git
was not created in the directory of subproject. I think this issue is fixed by https://github.com/ponder-lab/Logging-Level-Evolution-Plugin/pull/244
What happens if there's a .git directory already in a subproject prior to the analysis? Does it remove it?
What happens if there's a .git directory already in a subproject prior to the analysis? Does it remove it?
No, it doesn't remove anything. I tested just now. When the subproject had a .git
the directory which was generated by the previous version of code, the tool would throw an exception. Although the subproject has .git
directory, the tool doesn't think the subproject directory is a repo directory and throws an exception.
I am finding seeminly random
.git
directories on the machines where we are running the tool. They are appearing in my home directory, workspace directory, and code top-level directories. Is it possible for the tool to create git repositories?