git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Parkins <andyparkins@gmail.com>
To: git@vger.kernel.org
Subject: Re: Strange cogito behaviour
Date: Tue, 1 Aug 2006 16:41:16 +0100	[thread overview]
Message-ID: <200608011641.20077.andyparkins@gmail.com> (raw)
In-Reply-To: <20060801151258.GB3923@coredump.intra.peff.net>

[-- Attachment #1: Type: text/plain, Size: 1458 bytes --]

On Tuesday 2006 August 01 16:12, Jeff King wrote:

> A cogito fetch without a branch specifier defaults to the remote HEAD,
> not master.  This is the documented behavior (see cg-branch-add(1)). I
> agree it is confusing (I also thought it was a bug until I looked it up

Fair enough.  If it is working as intended, then I have no complaint.


> > The script then continues with
> >  * Switch repo1 back to master branch
> >  * Update repo2
> > This time repo2 doesn't change.  So I'm more confused :-)
>
> This is because repo2's master is already at the branch, and repo1 is a
> subset of that history. There is no need to merge since repo2 already
> contains all of the commits in repo1 (plus another one which is only on
> the branch in repo1).

I think I see now.  repo2 is neither repo1#master nor repo1#branch because it 
actually went like this:
 * repo1 cloned to repo2, repo2#master is repo1#master
 * repo2 fetches repo1#branch and /merges/ those changes
 * repo1#HEAD switched to HEAD=master
 * repo2 fetch does nothing because repo2 is actually
   repo1#master + repo1#branch, hence is newer than both
   repo1#master and repo1#branch
That explanation seems to fit exactly with the observed results, so would seem 
to be plausible.

Thank you for your help; I of course withdraw my bug report and apologise for 
bothering you all :-)


Andy


-- 
Dr Andy Parkins, M Eng (hons), MIEE
andyparkins@gmail.com

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

      reply	other threads:[~2006-08-01 15:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-01  9:53 Strange cogito behaviour Andy Parkins
2006-08-01 15:12 ` Jeff King
2006-08-01 15:41   ` Andy Parkins [this message]

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

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

  git send-email \
    --in-reply-to=200608011641.20077.andyparkins@gmail.com \
    --to=andyparkins@gmail.com \
    --cc=git@vger.kernel.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.
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 NNTP newsgroup(s).