Subject: Re: [PATCH] status: show default branch comparison when tracking non-default branch

From: Harald Nordgren <[email-masked]>
Date: Tue, 23 Dec 2025 15:09:24 +0100

> If a project uses the same remote repository to maintain its
> maintenance and development tracks, their HEAD might point at the
> 'main' (used for development), but some of your branches you used to
> work on fixes that can later be merged to the maintenance track, it
> is likely that you'll fork from their 'maint', and while you keep
> polishing your fixes, you may push your 'fix' branch to their 'fix'
> branch.  Comparing your 'fix' with their 'fix' is what we already
> do, and it gives two thirds of what you need, but the missing
> comparison is with their 'maint', not with their HEAD that points at
> their 'main'.

That's a fair point. I am used to trunk-based development, but I recognize
that there are other paradigms out there.

One possibly solution could be to make this adjustable in repo-wide config
(maybe 'repo.settings.defaultBranch=maint') and when unset it compares to
'refs/remotes/upstream/HEAD'?