Re: checking out branches: tracking vs. tags

Jim Abernathy

On 05/24/2012 11:21 AM, Chris Larson wrote:
On Thu, May 24, 2012 at 7:55 AM, jfabernathy<jfabernathy@...> wrote:
the Development Manual Appendix A
I see the statement:

$ git checkout denzil-7.0 -b denzil

What I think this does is create me a local branch that is fixed to what was
committed when the denzil-7.0 tag was created and it will remain that way
and will not track the denzil branch as it gets updated. Right????

Now if I want to track the denzil branch as changes are committed, I think I
do the following.

$ git checkout origin/denzil -b denzil

Now I can do git pull commands to get the updates that are committed.
Your arguments are backwards. See git help checkout.
I looked at git help and man git, but it is still unclear because if I do the first one where I checkout using the tag, I cannot git pull at all; I get an error, about not enough information to merge. However, if I use the name of the branch I can now do git pull when changes are committed to denzil. That's why I thought I understood it. But who knows.

Jim A

Join to automatically receive all group messages.