Skip to contentSkip to conversation

why "Not currently on any branch" but no "HEAD detached"?

DISCUSSION Robert P. J. Day 2 participants 3 messages Mar 30, 2020

lore
Share & tools
lore
#0 lore raw

probably a silly question (and probably related to using an old
version of git), but on a ubuntu 16.04.6 dev system, i used google's "repo" tool to check out a bunch of git repos, and when i pop into those git repos and run "git status", i see:

# Not currently on any branch
nothing to commit, working tree clean

i'm used to seeing "HEAD detached at <something>" ... is the above just an older style of the same message, given that this system uses git 2.9.2? or is there something else going on here?

rday

Signature · 7 lines
========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                         http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================
#1 lore raw
Quoted 11 lines · Robert P. J. Day

probably a silly question (and probably related to using an old
version of git), but on a ubuntu 16.04.6 dev system, i used google's "repo" tool to check out a bunch of git repos, and when i pop into those git repos and run "git status", i see:

# Not currently on any branch
nothing to commit, working tree clean

i'm used to seeing "HEAD detached at <something>" ... is the above just an older style of the same message, given that this system uses git 2.9.2? or is there something else going on here?

b397ea48 (status: show more info than "currently not on any branch", 2013-03-13) is the culprit. We used to just say the HEAD was detached, but for the past 7 years or so, when we know the last branch we were on before detaching, we report the name of the branch.

#2 lore raw
Quoted 14 lines · Junio C Hamano
Quoted 11 lines · Robert P. J. Day

probably a silly question (and probably related to using an old
version of git), but on a ubuntu 16.04.6 dev system, i used google's "repo" tool to check out a bunch of git repos, and when i pop into those git repos and run "git status", i see:

# Not currently on any branch
nothing to commit, working tree clean

i'm used to seeing "HEAD detached at <something>" ... is the above just an older style of the same message, given that this system uses git 2.9.2? or is there something else going on here?

Quoted 5 lines

b397ea48 (status: show more info than "currently not on any branch", 2013-03-13) is the culprit. We used to just say the HEAD was detached, but for the past 7 years or so, when we know the last branch we were on before detaching, we report the name of the branch.

got it, thanks.

rday