git/list[1] front-page[2] threads[3] people[4] search[5] about
 

RE: How to update a cloned git repository

From
Joachim Schmitz <jojo@schmitz-digital.de>
Date
Sep 11, 2012, 12:48 UTC
Message-ID
<007101cd901b$bea9d3d0$3bfd7b70$@schmitz-digital.de>
In-Reply-To
<vpq4nn4d968.fsf@bauges.imag.fr>
Show 7 quoted lines
> From: Matthieu Moy [mailto:Matthieu.Moy@grenoble-inp.fr]
> Sent: Tuesday, September 11, 2012 2:41 PM
> To: Joachim Schmitz
> Cc: git
> Subject: Re: How to update a cloned git repository
> 
> [ Re-adding git@vger in Cc, I guess it was meant to be so ]
Oops, yes it was meant to.
Show 28 quoted lines
> "Joachim Schmitz" <jojo@schmitz-digital.de> writes:
> 
> >> Then, work on the tip of the topic branch you depend on instead of pu.
> >> These are more stable, as they will be rewritten only if this particular
> >> topic branch changes.
> >
> > These are not available from git hub. Or are they? How?
> 
> I think they exist in some of the repos junio pushes to, but I don't
> remember how/which one.
> 
> Anyway, you can easily get it from the commit that merges the branch
> (it's the-merge-commit^1).
> 
> >> > Like this?
> >> > git pull --rebase HEAD~42
> >>
> >> That would be "git fetch" and then "git rebase", as I don't think "git
> >> pull --rebase" would allow you to specify the starting point for rebase.
> >
> > OK, I'll try that next time then. Like this?
> > 	git fetch;git rebase HEAD~42 --onto origin/pu
> 
> That should work, yes.
> 
> In general, when you have a somehow complex workflow, I recommand
> fetch+(merge|rebase) over pull. It gives you more flexibility, and the
> opportunity to check what you fetched before starting the merge.
OK, thanks.
I'm sure I'll have more questions later though ;-)
Previous: Matthieu MoyNext: Erik Faye-Lund
Message 9 of 14 in “How to update a cloned git repository”
  1. Joachim SchmitzSep 11, 2012
  2. Matthieu MoySep 11, 2012
  3. Joachim SchmitzSep 11, 2012
  4. Matthieu MoySep 11, 2012
  5. Sitaram ChamartySep 11, 2012
  6. Junio C HamanoSep 11, 2012
  7. Joachim SchmitzSep 11, 2012
  8. Matthieu MoySep 11, 2012
  9. Joachim SchmitzSep 11, 2012
  10. Erik Faye-LundSep 11, 2012
  11. Junio C HamanoSep 11, 2012
  12. Matthieu MoySep 11, 2012
  13. Joachim SchmitzSep 11, 2012
  14. Matthieu MoySep 12, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.