On my first uses of submodules they use to be always detached at HEAD because the git submodule add is only performing a checkout, so the proper way to add a submodule is by specifying also its branch in this way:
git submodule add -b <branch> <repository> [<submodule-path>]
On my first uses of submodules they use to be always detached at HEAD because the git submodule add is only performing a checkout, so the proper way to add a submodule is by specifying also its branch in this way:
git submodule add -b <branch> <repository> [<submodule-path>]