1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-05-28 13:56:16 +02:00

fetch: fix negotiate-only error message

The error message when invoking a negotiate-only fetch without providing
any tips incorrectly refers to a --negotiate-tip=* argument. Fix this to
use the actual argument, --negotiation-tip=*.

Signed-off-by: Robert Coup <robert@coup.net.nz>
Reviewed-by: Jonathan Tan <jonathantanmy@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Robert Coup 2022-01-28 14:36:02 +00:00 committed by Junio C Hamano
parent eff40457a4
commit 2826ffad8c
2 changed files with 2 additions and 2 deletions

View File

@ -1991,7 +1991,7 @@ int cmd_fetch(int argc, const char **argv, const char *prefix)
}
if (negotiate_only && !negotiation_tip.nr)
die(_("--negotiate-only needs one or more --negotiate-tip=*"));
die(_("--negotiate-only needs one or more --negotiation-tip=*"));
if (deepen_relative) {
if (deepen_relative < 0)

View File

@ -606,7 +606,7 @@ test_expect_success 'usage: --negotiate-only without --negotiation-tip' '
setup_negotiate_only "$SERVER" "$URI" &&
cat >err.expect <<-\EOF &&
fatal: --negotiate-only needs one or more --negotiate-tip=*
fatal: --negotiate-only needs one or more --negotiation-tip=*
EOF
test_must_fail git -c protocol.version=2 -C client fetch \