Re: git-rebase-walk
- From
- Nico 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