git-for-windows/git-sdk-64

sdk cd can't find refs/heads/master on fresh installs

rimrul opened this issue · 2 comments

When initially running sdk cd build-extra on a fresh install, it complains

error: refname refs/heads/master not found
fatal: Umbenennung des Branches fehlgeschlagen
Could not change directory to 'build-extra'

Umbenennung des Branches fehlgeschlagen means renaming the branch failed. The same thing happens on sdk cd git and sdk cd msys2-runtime. cd /usr/src/git (or /usr/src/build-extra or /usr/src/MSYS2-packages) followed by git pull origin main seems to fix the issue.

I can't quite figure out the source of the first error.

The second error seems to come from git-sdk.sh#L241.

The third error seems to come from git-sdk.sh#L195.