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

Re: Minor(?) usability issue with branch.<name>.pushRemote

From
Sergey Organov <sorganov@gmail.com>
Date
Dec 12, 2018, 11:18 UTC
Message-ID
<87d0q72du2.fsf@javad.com>
In-Reply-To
<xmqqh8fjhy8k.fsf@gitster-ct.c.googlers.com>
Junio C Hamano <gitster@pobox.com> writes:
Show 11 quoted lines
> Sergey Organov <sorganov@gmail.com> writes:
>
>> So, finally, it's 'branch.linux.pushremote' that is the "offender".
>>
>> Looks like both 'git status' and 'git branch -vv' should somehow learn
>> about 'branch.<name>.pushremote' feature so that their
>> output/suggestions make more sense?
>
> Doesn't "ahead of X by N" mean "you forked from X and built N commits
> on top", not "you have N commits that is not in X which is where you
> would push to"?
Sure, but the problem is that 'git status' gives exact suggestion:
 (use "git push" to publish your local commits)

that is somewhat misleading in this particular case ('git push' is now a no-op), and then 'git branch -vv', while tells me relationship to "upstream", keeps silence about non-matching push destination.

To add even more complexity to the case, notice that the first time after I committed locally, the invocation of 'git push' (exactly as suggested by 'git status') did successfully push those two commits, so the suggestion is exactly right before the commits are pushed, yet is rather misleading afterwards.

-- 
Sergey
Previous: Junio C Hamano
Message 3 of 3 in “Minor(?) usability issue with branch.<name>.pushRemote”
  1. Sergey OrganovDec 12, 2018
  2. Junio C HamanoDec 12, 2018
  3. Sergey OrganovDec 12, 2018

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.