> From: Roy Vardi <roy.va...@gmail.com>
> So basically you're saying that the only way for me to run git branch and
> see master is if I'm on the head of it?
> I thought that all branches are conceived of a history of commits, and
> checking out an older commit still means that I'm on the same branch...
Yes ... and no.
Look at the third image on
There are two branches, master and iss53. Following the ancester
pointers, each branch "has" a history of commits. But the commits
don't "belong" to any branch in particular. E.g., commit C1 is in the
history of both master and iss53.
(The fourth image is even more interesting.)
If you checked out commit C1, and then made a new commit, Git has no
idea which branch you'd like to update. Now I just checked, and you
*can* create a new commit, but no branch points to it, so you'll have
a hard time finding it later. Indeed, if you move the working copy to
some branch, there will be no references pointing to the new commit,
and it will eventually be garbage collected.
You received this message because you are subscribed to the Google Groups "Git
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email
For more options, visit https://groups.google.com/groups/opt_out.