Subject: Re: [PATCH v2 1/2] status: show comparison with upstream default branch

From: Junio C Hamano <[email-masked]>
Date: Wed, 24 Dec 2025 10:46:30 +0900

"brian m. carlson" <[email-masked]> writes:

> On 2025-12-23 at 22:54:07, Harald Nordgren via GitGitGadget wrote:
>> +static char *get_default_remote_ref(char **full_ref_out)
>> +{
>> +	int flag;
>> +	const char *resolved;
>> +	static const char *remotes[] = { "upstream", "origin", NULL };
>
> This should definitely be configurable, not hard-coded.  For instance, I
> have this in my gitconfig:
>
>     [clone]
>         defaultRemoteName = def
>
> so my default remote name is `def` (short for "default", as in the
> default place to push) and this code will never work.

But there does not need any new configuration.  "git pull" and "git
push" on the branch is equipped to figure out where they pull from
and push to, so the new feature should be able to figure out these
(often the same, but not necessarily) repositories the same way.