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

Re: git-rebase-walk

From
NWNico Williams <nico@cryptonector.com>
Date
Oct 6, 2026, 14:58 UTC
Message-ID
<asUMkBi9NG0k6fu4@ubby>
In-Reply-To
<792f4d41-bd60-4fae-a426-bd70cbad996c@gmail.com>
On Tue, Oct 06, 2026 at 03:01:29PM +0100, Phillip Wood wrote:
Show 13 quoted lines
> On 05/10/2026 14:37, Alejandro Colomar wrote:
> > > Below is a shell session performing such a rebase, which hopefully shows
> > > why I need this to be multi-shot.
> 
> To me it shows that we need to improve "git rebase --update-refs" so that it
> can rebase a tree of branches automatically. Doing it manually is labor
> intensive and error-prone (your example output shows it is easy to forget
> when you're meant to be resolving a conflict instead aborting the rebase and
> checking out another branch). In the example below
> 
>     git rebase --update-refs --rebase-merges main B
> 
> will rebase A and B, but we don't have a way of including C.

But it's not the same problem. This isn't about rebasing a set of stacked branches all at once. This is about rebasing quickly across thousands of upstream commits.

Naturally one _could_ use `--update-refs` with a bisect-rebase. The two features are orthogonal.

I've been using this bisect-rebase script to rebase an old branch off PG to the latest upstream -- that's 10,135 commits in my case(!).

Show 7 quoted lines
> > > On the simpler case of a single branch, I'd still prefer a multi-shot
> > > approach where --continue only advances one rebase operation, because at
> > > the end of it I want to stop, and check git-range-diff(1) to make sure
> > > it all makes sense.
> 
> Perhaps we could insert "break" commands after each branch is rebased so the
> user can check the range-diff.

The bisect-rebase scripts do stop when a conflict is found that the user should resolve. The noise from the bisection's search for that appropriate commit is not that interesting except as a sort of progress meter. Stopping at each point in the bisection where the bisection would continue is not going to be that useful unless the user could check if the conflicts are simple and obvious enough at each point and skip the rest of the bisection -- is that your idea? But if so then the bisection will be very painful if the user would mostly elect to continue it. That could be an option -- if it works, great, and if not start over without that option.

Nico
Previous: Phillip WoodNext: Alejandro Colomar
Message 11 of 21 in “git-rebase-walk”
  1. Alejandro ColomarOct 1, 2026
  2. Patrick SteinhardtOct 1, 2026
  3. Alejandro ColomarOct 1, 2026
  4. Patrick SteinhardtOct 2, 2026
  5. Alejandro ColomarOct 2, 2026
  6. Nico WilliamsOct 3, 2026
  7. Phillip WoodOct 4, 2026
  8. Alejandro ColomarOct 5, 2026
  9. Alejandro ColomarOct 5, 2026
  10. Phillip WoodOct 6, 2026
  11. Nico WilliamsOct 6, 2026
  12. Alejandro ColomarOct 6, 2026
  13. Junio C HamanoOct 1, 2026
  14. Nico WilliamsOct 1, 2026
  15. Alejandro ColomarOct 1, 2026
  16. Nico WilliamsOct 1, 2026
  17. Alejandro ColomarOct 1, 2026
  18. Nico WilliamsOct 1, 2026
  19. Nico WilliamsOct 1, 2026
  20. Simon RichterOct 2, 2026
  21. Nico WilliamsOct 2, 2026

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.