unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: David Kastrup <dak@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: Obscure error/warning/information message from git pull
Date: Sat, 15 Nov 2014 13:13:28 +0200	[thread overview]
Message-ID: <83ppcog1if.fsf@gnu.org> (raw)
In-Reply-To: <878ujcoj0k.fsf@fencepost.gnu.org>

> From: David Kastrup <dak@gnu.org>
> Cc: emacs-devel@gnu.org
> 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.

> > For example, "git clone" is advertised as "clone a repository", but
> > that evidently only "fully" clones the master branch; other branches
> > won't even be updated by the following "git pull"s unless you say
> > "git checkout BRANCH" once (or give some other command that has the
> > same effect).  Then what exactly is brought downstream by 'clone', and
> > why is it called "repository" rather than "branch"?
> 
> The manual is clear about that.

"Clear", right.

>        Clones a repository into a newly created directory, creates
>        remote-tracking branches for each branch in the cloned repository
>        (visible using git branch -r), and creates and checks out an initial
>        branch that is forked from the cloned repository\u2019s currently active
>        branch.
> 
>        After the clone, a plain git fetch without arguments will update all
>        the remote-tracking branches, and a git pull without arguments will in
>        addition merge the remote master branch into the current master branch,
>        if any (this is untrue when "--single-branch" is given; see below).
> 
>        This default configuration is achieved by creating references to the
>        remote branch heads under refs/remotes/origin and by initializing
>        remote.origin.url and remote.origin.fetch configuration variables.

Sorry, but that's a bunch of gobbledygook.  What does "create
remote-tracking branches" mean, and how is it different from "creates
the initial branch"?  What does "update" in "update the
remote-tracking branches" means, and how is it different from what is
described after that for the master branch?  Sorry, but this old
curmudgeon cannot grok that; I'd very much prefer your own words.

> > 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?  Below you seem to
say it doesn't; but in that case, how would Git "know what's there"
and show that to me while offline?

> git-pull merges (or rebases) _one_ local branch.  The one that is
> checked out.  But it updates all remote-tracking branches.

"Updates" how?  Does it update their part of the DAG?  Does it do
something else?

> > These and other similar complexities stand in the way of my
> > understanding of what exactly do I have in my clone of the repository,
> > and what I don't have.
> 
> git branch -a should tell you.

It shows the list of the branches, where I know how to discern a
branch I call "tracking", i.e. the one for which I did a checkout at
some point, and those for which I didn't.  What else should it tell
me?

> > 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?

Thanks for taking time to explain this.



  reply	other threads:[~2014-11-15 11:13 UTC|newest]

Thread overview: 124+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-14 12:06 Obscure error/warning/information message from git pull Alan Mackenzie
2014-11-14 13:10 ` Tassilo Horn
2014-11-14 13:44   ` Andreas Schwab
2014-11-14 14:14   ` Andrew Burgess
2014-11-14 18:05     ` Alan Mackenzie
2014-11-14 18:58       ` Andreas Schwab
2014-11-14 20:09         ` Alan Mackenzie
2014-11-14 20:41           ` Christoph
2014-11-14 20:52           ` Andreas Schwab
2014-11-14 22:04             ` Alan Mackenzie
2014-11-15  7:28               ` Tassilo Horn
2014-11-15 19:40           ` Florian Weimer
2014-11-15 21:45             ` Alan Mackenzie
2014-11-15 22:02               ` Florian Weimer
2014-11-16  9:10               ` David Kastrup
2014-11-20  2:56             ` Rob Browning
2014-11-14 20:50       ` Tassilo Horn
2014-11-14 20:57       ` Sergey Organov
2014-11-14 21:27         ` Eli Zaretskii
2014-11-14 23:56           ` Michael Welsh Duggan
2014-11-15  7:36             ` David Kastrup
2014-11-14 23:02         ` Alan Mackenzie
2014-11-14 23:17           ` David Engster
2014-11-15  7:52             ` Eli Zaretskii
2014-11-15  8:18               ` David Engster
2014-11-15  8:54                 ` Eli Zaretskii
2014-11-14 23:40           ` David Caldwell
2014-11-15  7:40           ` David Kastrup
2014-11-15  8:43             ` Eli Zaretskii
2014-11-15  9:12               ` David Kastrup
2014-11-15  9:53                 ` Eli Zaretskii
2014-11-15 10:28                   ` David Kastrup
2014-11-15 11:13                     ` Eli Zaretskii [this message]
2014-11-15 14:30                       ` David Kastrup
2014-11-15 17:56                         ` Eli Zaretskii
2014-11-15 18:17                           ` David Kastrup
2014-11-15 12:05                     ` Alan Mackenzie
2014-11-15 14:35                       ` David Kastrup
2014-11-15 15:57                         ` Michael Welsh Duggan
2014-11-15 16:56                           ` David Kastrup
2014-11-15 19:57                         ` Alan Mackenzie
2014-11-15 20:48                           ` Achim Gratz
2014-11-16  9:33                             ` David Kastrup
2014-11-16  9:23                           ` David Kastrup
2014-11-16 15:28                             ` Eli Zaretskii
2014-11-16 15:47                               ` David Kastrup
2014-11-16 13:25           ` Thien-Thi Nguyen
2014-11-16 15:26             ` Tassilo Horn
2014-11-16 15:35             ` Eli Zaretskii
2014-11-16 16:16               ` David Kastrup
2014-11-16 16:44                 ` Andreas Schwab
2014-11-16 17:54                 ` Eli Zaretskii
2014-11-16 20:24               ` Thien-Thi Nguyen
2014-11-17 11:54           ` Sergey Organov
2014-11-17 14:11             ` Alan Mackenzie
2014-11-18 16:59               ` Sergey Organov
2014-11-18 17:33                 ` Eli Zaretskii
2014-11-18 17:58                   ` Sergey Organov
2014-11-18 18:18                     ` Eli Zaretskii
2014-11-18 18:40                       ` David Kastrup
2014-11-18 18:53                         ` Eli Zaretskii
2014-11-18 20:57                       ` Sergey Organov
2014-11-18 22:43                         ` Alan Mackenzie
2014-11-19  0:48                           ` Barry Warsaw
2014-11-19  9:50                             ` David Kastrup
2014-11-19  1:12                           ` Yuri Khan
2014-11-19 16:18                             ` Eli Zaretskii
2014-11-19 16:39                               ` Sergey Organov
2014-11-19 16:49                               ` Yuri Khan
2014-11-19  4:48                           ` Teemu Likonen
2014-11-19  6:57                             ` Stephen J. Turnbull
2014-11-19 13:55                               ` Teemu Likonen
2014-11-19  8:22                           ` Thien-Thi Nguyen
2014-11-19 12:14                           ` Achim Gratz
2014-11-19 13:55                             ` Alan Mackenzie
2014-11-19 15:00                               ` David Kastrup
2014-11-19 15:15                               ` Sergey Organov
2014-11-19 15:24                               ` Achim Gratz
2014-11-19 15:36                                 ` David Kastrup
2014-11-19 16:00                                 ` Sergey Organov
2014-11-19 16:42                               ` Stephen J. Turnbull
2014-11-20  0:57                               ` Alexis
2014-11-20 15:52                                 ` Eli Zaretskii
2014-11-19 16:20                             ` Eli Zaretskii
2014-11-19 16:36                               ` Sergey Organov
2014-11-19 18:40                                 ` Stephen J. Turnbull
2014-11-19 18:48                                 ` Eli Zaretskii
2014-11-19 20:05                                   ` David Kastrup
2014-11-19 20:14                                     ` Eli Zaretskii
2014-11-20  3:01                                       ` Stephen J. Turnbull
2014-11-20 15:53                                         ` Eli Zaretskii
2014-11-19 18:29                               ` Teemu Likonen
2014-11-18 23:07                         ` Stephen J. Turnbull
2014-11-18 23:35                           ` Alan Mackenzie
2014-11-19  1:31                             ` Stephen J. Turnbull
2014-11-19  3:43                         ` Eli Zaretskii
2014-11-18 21:59                       ` John Yates
2014-11-19  3:47                         ` Eli Zaretskii
2014-11-19 10:08                           ` David Kastrup
2014-11-19 16:19                             ` Eli Zaretskii
2014-11-18 22:59                   ` Stephen J. Turnbull
2014-11-19 16:16                     ` Eli Zaretskii
2014-11-19 16:48                       ` Stephen J. Turnbull
2014-11-19 18:44                         ` Eli Zaretskii
2014-11-14 21:04       ` David Kastrup
2014-11-14 13:46 ` Andreas Schwab
2014-11-14 13:59   ` Lars Magne Ingebrigtsen
2014-11-14 14:08   ` Tassilo Horn
2014-11-14 15:51     ` Andreas Schwab
2014-11-14 15:53       ` Lars Magne Ingebrigtsen
2014-11-14 20:41         ` Tassilo Horn
2014-11-14 20:52           ` Eli Zaretskii
2014-11-14 16:48       ` Eli Zaretskii
2014-11-14 14:38   ` Eli Zaretskii
2014-11-14 15:50     ` Andreas Schwab
2014-11-14 16:47       ` Eli Zaretskii
2014-11-14 17:03     ` Michael Welsh Duggan
2014-11-14 17:23       ` Eli Zaretskii
2014-11-14 17:30         ` Andreas Schwab
2014-11-14 20:30           ` Eli Zaretskii
2014-11-14 21:12             ` Andreas Schwab
2014-11-14 21:28               ` Eli Zaretskii
2014-11-14 21:18         ` David Kastrup
2014-11-14 21:35           ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83ppcog1if.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=dak@gnu.org \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).