[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Obscure error/warning/information message from git pull
From: |
Eli Zaretskii |
Subject: |
Re: Obscure error/warning/information message from git pull |
Date: |
Sat, 15 Nov 2014 19:56:46 +0200 |
> From: David Kastrup <address@hidden>
> Cc: address@hidden
> Date: Sat, 15 Nov 2014 15:30:31 +0100
>
> Eli Zaretskii <address@hidden> writes:
>
> >> From: David Kastrup <address@hidden>
> >> Cc: address@hidden
> >> Date: Sat, 15 Nov 2014 11:28:11 +0100
> >>
> >> >> git cannot magically show anything that isn't in the repo.
> >> >
> >> > It is unclear to me, at my current level of knowledge, what exactly
> >> > "is in the repo".
> >>
> >> All the references you fetched/cloned and everything they point to.
> >
> > Thanks, but that explains nothing.
> [...]
Thanks, that's a lot to digest. A couple of questions:
> >> > Furthermore, even if you have other branches tracked, "git pull"
> >> > evidently won't update them as it does with the current branch, since
> >> > switching to another branch after a pull will cheerfully tell you that
> >> > you are behind the branch tip and need another "git pull" to fix that.
> >> > Then what exactly does "branch tracking" mean, by default?
> >>
> >> It means that Git tracks the remote branches: it knows what's there and
> >> can show you even when offline (of course, it shows the state since the
> >> last fetch).
> >
> > Does that include updating their parts of the DAG?
>
> Yes.
> [...]
> >> > It is all the more perplexing, since (AFAIU) the repo met-data is (or
> >> > includes) the history DAG, where (AFAIK) branches are all interwoven
> >> > in a single graph. So how come a 'pull' doesn't update the whole DAG,
> >> > and if it does, why do I need to do something in addition to have all
> >> > my branches updated?
> >>
> >> A pull updates those parts of the DAG that can be reached from the
> >> references you have in your "fetch" specification.
> >
> > What is my "fetch specification", and how did I specify that?
>
> Take a look in your .git/config file. You'll find a section
> [remote "origin"] containing, among other things, a fetch specification.
That says "fetch = +refs/heads/*:refs/remotes/origin/*", which I guess
means everything, and is probably the default (since I never said
anything about that). So I guess I can now forget everything about
partial DAG being fetched, because in my case, as in every default
case, the entire DAG will be updated by "git pull". Is that correct?
> For a typical repository containing all branches (whether that is the
> case depends on the fetch specification), the complete DAG is
> available. git pull updates _all_ fetched remote-tracking branches.
> But it only merges the currently checked-out _local_ branch with the
> remote-tracking branch for the corresponding remote branch.
So the suggestion to pull, displayed by Git when I checkout another
branch immediately after a pull, actually boils down to do the merge
for that other branch? If so, why does it suggest a pull?
Thanks.
- Re: Obscure error/warning/information message from git pull, (continued)
- Re: Obscure error/warning/information message from git pull, Eli Zaretskii, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Engster, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Eli Zaretskii, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Eli Zaretskii, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Eli Zaretskii, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Eli Zaretskii, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/15
- Re: Obscure error/warning/information message from git pull,
Eli Zaretskii <=
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Alan Mackenzie, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Michael Welsh Duggan, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Alan Mackenzie, 2014/11/15
- Re: Obscure error/warning/information message from git pull, Achim Gratz, 2014/11/15
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/16
- Re: Obscure error/warning/information message from git pull, David Kastrup, 2014/11/16
- Re: Obscure error/warning/information message from git pull, Eli Zaretskii, 2014/11/16