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

Heads up: major rebase -i -p rework coming up

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Jan 24, 2009, 20:25 UTC
Message-ID
<alpine.DEB.1.00.0901242056070.14855@racer>
Hi all,

as probably everybody agrees, the code to preserve merges is a big mess right now.

Worse, the whole concept of "pick <merge-sha1>" just does not fly well.

So I started a _major_ cleanup, which happens to reduce the code very nicely so far.

It will take a few days to flesh out, I guess, but these are the major ideas of my work:

- pick $sha1
	will only work on non-merges in the future
- merge $sha1 [$sha1...] was $sha1 "Merge ..."
	will merge the given list of commits into the current HEAD, for 
	the user's reference and to keep up-to-date what was rewritten, 
	the original merge is shown after the keyword "was" (which is not 
	a valid SHA-1, luckily)
- goto $sha1
	will reset the HEAD to the given commit
- $sha1'
	for merge and goto, if a $sha1 ends in a single quote, the 
	rewritten commit is substituted (if there is one)
Example:
A - B - - - E 
  \       /
    C - D
could yield this TODO script:
	pick A
	pick C
	pick D
	goto A'
	pick B
	merge D' was E
This should lead to a much more intuitive user experience.

I am very sorry if somebody actually scripted rebase -i -p (by setting GIT_EDITOR with a script), but I am very certain that this cleanup is absolutely necessary to make rebase -i -p useful.

As always, I am thankful for suggestions to make this even more useful, or even easier to operate.

Ciao, Dscho

Next: Junio C Hamano
Message 1 of 27 in “Heads up: major rebase -i -p rework coming up”
  1. Johannes SchindelinJan 24, 2009
  2. Junio C HamanoJan 24, 2009
  3. Johannes SchindelinJan 24, 2009
  4. Johannes SchindelinJan 24, 2009
  5. Junio C HamanoJan 24, 2009
  6. Johannes SchindelinJan 25, 2009
  7. Marc BranchaudJan 26, 2009
  8. Thomas RastJan 24, 2009
  9. Johannes SchindelinJan 25, 2009
  10. Johannes SchindelinJan 25, 2009
  11. Jakub NarebskiJan 25, 2009
  12. Johannes SchindelinJan 25, 2009
  13. Sverre RabbelierJan 25, 2009
  14. Johannes SchindelinJan 25, 2009
  15. Junio C HamanoJan 25, 2009
  16. Johannes SchindelinJan 25, 2009
  17. Jakub NarebskiJan 25, 2009
  18. Johannes SchindelinJan 25, 2009
  19. Nanako ShiraishiFeb 3, 2009
  20. Johannes SchindelinFeb 3, 2009
  21. Jakub NarebskiJan 25, 2009
  22. Björn SteinbrinkJan 25, 2009
  23. Marc BranchaudJan 26, 2009
  24. Stephen HabermanJan 27, 2009
  25. Johannes SchindelinJan 27, 2009
  26. Nanako ShiraishiJan 27, 2009
  27. Stephen HabermanJan 27, 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.