aboutsummaryrefslogtreecommitdiffstats
path: root/builtin/commit.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2024-07-02 12:57:47 -0700
committerJunio C Hamano <gitster@pobox.com>2024-07-02 15:06:13 -0700
commit4d8ee0317f01df5b6f3b41ed1bcb3dc6baecd464 (patch)
treeefb4bfaf7dadab3c989ede13fb6faf1684323557 /builtin/commit.c
parentGit 2.43.5 (diff)
downloadgit-4d8ee0317f01df5b6f3b41ed1bcb3dc6baecd464.tar.gz
git-4d8ee0317f01df5b6f3b41ed1bcb3dc6baecd464.zip
push: avoid showing false negotiation errors
When "git push" is configured to use the push negotiation, a push of deletion of a branch (without pushing anything else) may end up not having anything to negotiate for the common ancestor discovery. In such a case, we end up making an internal invocation of "git fetch --negotiate-only" without any "--negotiate-tip" parameters that stops the negotiate-only fetch from being run, which by itself is not a bad thing (one fewer round-trip), but the end-user sees a "fatal: --negotiate-only needs one or more --negotiation-tip=*" message that the user cannot act upon. Teach "git push" to notice the situation and omit performing the negotiate-only fetch to begin with. One fewer process spawned, one fewer "alarming" message given the user. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
0 files changed, 0 insertions, 0 deletions