And one more quote from the same stack overflow answer, “it will still allow you to make commits (which will update HEAD), so the above short definition is still true if you think of a detached HEAD as a temporary branch without a name.”
What? We can still make commits? in a detached HEAD state?
Let’s be brave and give it a try in the visualization tool.
If we do a ‘git commit’ in the detached HEAD state, the visualization tools shows a commit being made to the side.
P.S. Have I proclaimed my love of this git visualization tool yet today?
So what on earth now? we have this thing floating out in nowhere. Well, we know it is a nameless branch… and we know we can merge branches… let’s try to merge it!
First, we’ll checkout master.
Then we’ll do the merge and verify the git log.
and thus conclude my mathematical proof I truly have no idea how people are able to keep track of these one-off commits or whatever is going on in git without visualization tools. QED.