git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Francis Moreau <francis.moro@gmail.com>
To: "Johan 't Hart" <johanthart@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: Question about "git pull --rebase"
Date: Mon, 16 Nov 2009 13:17:51 +0100	[thread overview]
Message-ID: <38b2ab8a0911160417w6b9cc943h5e87d4e22d0dea2b@mail.gmail.com> (raw)
In-Reply-To: <4AFF3D4D.7000308@gmail.com>

On Sun, Nov 15, 2009 at 12:29 AM, Johan 't Hart <johanthart@gmail.com> wrote:
> This does not update any remote tracking branches, but it will rebase your
> foo branch on the remote master branch (which is what you want)
> It could also be done with:
>
> git pull --rebase origin master:origin/master
>
> This will also update your remote tracking branch refs/remotes/origin/master
> to match the master branch on the remote repo. Your foo branch will then be
> rebased onto it.

BTW, this seems to be not exact.

$ git pull --rebase origin master:origin/master

fetches the 'master' branch on the remote repo, then creates a new
branch 'origin/master', which is updated with the fetched branch.

To update the remote tracking branch refs/remotes/origin/master, I
need to issue:

$ git pull --rebase origin master:remotes/origin/master

BTW2,  it looks like if the <dst> local ref doesn't exist the it will
be created. This something that appears very lately in the man page
(actually I can see the information only in the last example). This
could be part of the <refspec> defintion.

Thanks
-- 
Francis

      parent reply	other threads:[~2009-11-16 12:20 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-14 20:39 Question about "git pull --rebase" Francis Moreau
2009-11-14 23:16 ` Nanako Shiraishi
2009-11-15 14:31   ` Francis Moreau
2009-11-14 23:29 ` Johan 't Hart
2009-11-15 14:34   ` Francis Moreau
2009-11-15 19:47     ` Johan 't Hart
2009-11-15 20:18       ` Junio C Hamano
2009-11-15 20:32         ` Johan 't Hart
2009-11-16 12:00           ` Francis Moreau
2009-11-16 12:17   ` Francis Moreau [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=38b2ab8a0911160417w6b9cc943h5e87d4e22d0dea2b@mail.gmail.com \
    --to=francis.moro@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=johanthart@gmail.com \
    /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).