Description
Hi, So I'm very keen to use GitVersion in our groups repo to replace some versioning scripts. When I used GitVerion in a test repo to trial it and learn how it works everything was great. Now I've added it into our teams repo I'm starting to encounter performance issues.
Namely our builds without GitVersion (master) take ~1 min with GitVersion (my topic branch) it takes ~3 mins. I was expecting maybe a small overhead but this is took much to accept. The additional time is on the MSBUILD step.
We use VSTS run the build on our established agent build servers. Our solution contains 20 projects each with the GitVersion Targets NuGet Package now installed. When I inspect the logs emitted by the build (MSBuild) I can see GitVersion is spewing lots of INFO events along these lines:
Begin: Normalizing git directory for branch 'refs/heads/JD/GitVersion' (Count 56)
Creating local branch from remote tracking 'refs/remotes/origin/[DevIntial]/[BranchName' (Count 202)
Skipping update of 'refs/remotes/origin/[DevIntial]/[BranchName]' as it already matches the remote ref. (Count 8,327)
Begin: Finding merge base between '[DevIntial]/[BranchName]' and '[DevIntial]/[BranchName]' (Count 1,248)
End: Finding merge base between '[DevIntial]/[BranchName]' and '[DevIntial]/[BranchName]' (Count 1,248)
#1327 Might be similar
I'd like to understand what is going on and why it seems to be spending so much time iterating over all the remote branches if indeed that is where the time is being lost.
I noticed this:
No branch configuration found for branch JD/GitVersion, falling back to default configuration
is this why it is spending so much time doing the merge base operations?
I've attached our GitVerion.yml for reference
GitVersion.txt