Description
Error fatal: Cannot lock ref 'refs/heads/Branch1': unable to create directory for .git/refs/heads/Branch1 when checking out a branch into a repostiory that was created using GetNewWorkDir
Steps to reproduce:
1.) Clone a repository to C:\Dev\Projects_TRUNK via https from some source code server
2.) Use GitNewWorkDir to create a new working directory C:\Dev\Projects_Branch1 that uses C:\Dev\Projects_TRUNK as it's base directory
3.) cd to C:\Dev\Projects_Branch1 and execute: git checkout -B Branch1 "remotes/origin/Branch1"
4.) This will give error: fatal: Cannot lock ref 'refs/heads/Branch1': unable to create directory for .git/refs/heads/Branch1
As far as I can tell this appears to be a regression bug from Git-2.4.1.1-dev-preview-64-bit.exe
I found that calling (git checkout -B Branch1 "remotes/origin/Branch1") works as expected in:
Git-2.4.1.1-dev-preview-64-bit.exe
When I went to upgrade to a newer version of Git-For-Windows (Git-2.4.4.2-3rd-release-candidate-64-bit.exe), I found that calling (git checkout -B Branch1 "remotes/origin/Branch1") gives error (fatal: Cannot lock ref 'refs/heads/Branch1': unable to create directory for .git/refs/heads/Branch1)
I found that it is also broken in: Git-2.4.3.1-2nd-release-candidate-64-bit.exe
The exe's I am referring to are the ones that dscho released in:
https://github.com/git-for-windows/git/releases