"fatal: reference is not a tree: <sha>" on git checkout

ukio's Avatar


28 Dec, 2014 01:24 AM

I was hitting this several times now, e.g. here:

git clone -q --depth=1 --branch=master git://github.com/tknerr/vagrant-appveyor-testing.git C:\projects\vagrant-appveyor-testing
git checkout -qf 68d37132a66e00582127b69323e521e3ae2240ec
fatal: reference is not a tree: 68d37132a66e00582127b69323e521e3ae2240ec
Command exited with code 128

Builds were triggered via the Github integration / after commit hook.

Any ideas? Is this a known issue?

  1. Support Staff 1 Posted by Feodor Fitsner on 28 Dec, 2014 02:03 AM

    Feodor Fitsner's Avatar

    I think the problem is that it's toooo shallow. You should be very careful with --depth=1 because by the time build start there might be a new commit on top of it.

  2. 2 Posted by ukio on 28 Dec, 2014 02:18 AM

    ukio's Avatar

    Thanks, that was the culprit indeed. I just removed depth completely for this project...

  3. ukio closed this discussion on 28 Dec, 2014 02:18 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac