Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2024-01-03 00:51:29 +0300
committerJunio C Hamano <gitster@pobox.com>2024-01-03 00:51:29 +0300
commit43ec8791692f70768fa8eb23056db6a4e0ba3c6a (patch)
tree3aab7abf173589adb377e4bc8ded92a766fd7661 /builtin
parent9cc710098bb9aa3efcefcb5237d001ed09a52e50 (diff)
parenta762af3dfd9450bf1d6153faa620cb42efb7daa8 (diff)
Merge branch 'jc/retire-cas-opt-name-constant'
Code clean-up. * jc/retire-cas-opt-name-constant: remote.h: retire CAS_OPT_NAME
Diffstat (limited to 'builtin')
-rw-r--r--builtin/push.c4
-rw-r--r--builtin/send-pack.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/builtin/push.c b/builtin/push.c
index 6ec6165725..c95b69f7d7 100644
--- a/builtin/push.c
+++ b/builtin/push.c
@@ -392,7 +392,7 @@ static int push_with_options(struct transport *transport, struct refspec *rs,
if (!is_empty_cas(&cas)) {
if (!transport->smart_options)
die("underlying transport does not support --%s option",
- CAS_OPT_NAME);
+ "force-with-lease");
transport->smart_options->cas = &cas;
}
@@ -599,7 +599,7 @@ int cmd_push(int argc, const char **argv, const char *prefix)
OPT_BIT('n' , "dry-run", &flags, N_("dry run"), TRANSPORT_PUSH_DRY_RUN),
OPT_BIT( 0, "porcelain", &flags, N_("machine-readable output"), TRANSPORT_PUSH_PORCELAIN),
OPT_BIT('f', "force", &flags, N_("force updates"), TRANSPORT_PUSH_FORCE),
- OPT_CALLBACK_F(0, CAS_OPT_NAME, &cas, N_("<refname>:<expect>"),
+ OPT_CALLBACK_F(0, "force-with-lease", &cas, N_("<refname>:<expect>"),
N_("require old value of ref to be at this value"),
PARSE_OPT_OPTARG | PARSE_OPT_LITERAL_ARGHELP, parseopt_push_cas_option),
OPT_BIT(0, TRANS_OPT_FORCE_IF_INCLUDES, &flags,
diff --git a/builtin/send-pack.c b/builtin/send-pack.c
index 00e6c90477..e12054a78e 100644
--- a/builtin/send-pack.c
+++ b/builtin/send-pack.c
@@ -205,7 +205,7 @@ int cmd_send_pack(int argc, const char **argv, const char *prefix)
OPT_BOOL(0, "stateless-rpc", &stateless_rpc, N_("use stateless RPC protocol")),
OPT_BOOL(0, "stdin", &from_stdin, N_("read refs from stdin")),
OPT_BOOL(0, "helper-status", &helper_status, N_("print status from remote helper")),
- OPT_CALLBACK_F(0, CAS_OPT_NAME, &cas, N_("<refname>:<expect>"),
+ OPT_CALLBACK_F(0, "force-with-lease", &cas, N_("<refname>:<expect>"),
N_("require old value of ref to be at this value"),
PARSE_OPT_OPTARG, parseopt_push_cas_option),
OPT_BOOL(0, TRANS_OPT_FORCE_IF_INCLUDES, &force_if_includes,