Basically the opposite of this question.
I'm cloning a repo that has a submodule in it. After running
git submodule init
git submodule update
when I cd
to the subdirectory that contains the submodule, I expect to see that I am in a detached HEAD state when I do git status
but I'm not. I read up on submodules and I see you can setup tracking for a submodule but I have never done those steps.
I've reproduced this behavior with fresh clones of the repo in different directories; it's as if the submodules are being setup to be tracked right away somehow. My co-worker running on the same machine, same version of git, same .gitconfig (except usernames) gets the expected behavior (detached HEAD in submodule directory) with the same repository.