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

Re: How to merge in different order?

From
JWJosef Wolf <jw@raven.inka.de>
Date
Apr 3, 2009, 17:59 UTC
Message-ID
<20090403175924.GD28619@raven.wolf.lan>
In-Reply-To
<20090403163150.GD8155@coredump.intra.peff.net>
On Fri, Apr 03, 2009 at 12:31:50PM -0400, Jeff King wrote:
[ ... ]
> But what you probably want to do is rewrite the history of your branch
> to re-order the commits.

Yeah, That's exactly what I need. But I guess there's a lot of work ahead: about 2500 commits are waiting for the sort.

> You can do this with "git rebase -i".
Sounds good
Show 5 quoted lines
> Like any
> history rewriting, this can cause difficulties for people who you have
> already shared the branch with (because it will replace the commits that
> they already have with 5 _new_ commits that just happen to do more or
> less the same thing).

This is a copy of a svn repository, created with git-svn. So the branch is shared with other people.

> If you have already shared the branch, you may just want to cherry-pick
> the changes you want (using "git cherry-pick") onto your other branch.
Argh, I was looking for git-cherry, but that does something different ;-)
Thanks for the answer, Jeff!
Previous: Jeff King
Message 4 of 4 in “How to merge in different order?”
  1. Josef WolfApr 3, 2009
  2. Peter HarrisApr 3, 2009
  3. Jeff KingApr 3, 2009
  4. Josef WolfApr 3, 2009

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.