git submodule error: “fatal: reference is not a tree”

Common error while updating a git submodule:

fatal: reference is not a tree: 9b65a5f376fd806c5f989f0a69e00ada391dabf4
Unable to checkout '9b65a5f376fd806c5f989f0a69e00ada391dabf4' in submodule path 'path/to/submodule'

Quick fix:

1
2
git submodule sync
git submodule update

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>