From: Harald Nordgren Date: Tue, 13 Jan 2026 12:11:18 GMT Subject: Re: [PATCH v17 1/2] refactor format_branch_comparison in preparation Message-ID: <20260113121118.49541-1-haraldnordgren@gmail.com> In-Reply-To: > I'm not suggesting we design the feature around 'push.default=upstream', > I'm suggesting that we design it to respect 'push.default' so it gives > sensible output (i.e. something that resembles what "git push" would do) > whatever the setting. I guess I'm still not getting it, maybe explain it like I'm more stupid 😅 'push.default' does not change the output of git status, which shows a comparison with the tracking branch. I wrote the code to only report push branch status when it differs from the upstream. If we use 'push.default=upstream' they will be the same, so no need to report it twice. > Thanks, I think that would be cleaner It's in the latest patch now. > I can see tests for > > - upstream differs from the local branch, no push branch shown > - upstream and push branches differ from the local branch > - upstream and push branches match the local branch > > I can't see a test for the local branch differing from the upstream > branch when the push branch matches the local branch. As far as I can see > in that case we don't show the advice when we should do (and we currently > do show it) I added a test for this now, which I think proves that it's working correctly: ``` test_expect_success 'status with upstream ahead and push branch up to date' ' ``` Harald