aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRené Scharfe <l.s.r@web.de>2025-11-24 21:33:24 +0100
committerJunio C Hamano <gitster@pobox.com>2025-11-24 14:59:02 -0800
commitdf963f0df4756fa751bfbb39e104d004e3f7d60b (patch)
tree49ec460f6af1732bf59b031913ec2d29df4afb3b
parentbb5c624209fcaebd60b9572b2cc8c61086e39b57 (diff)
downloadgit-df963f0df4756fa751bfbb39e104d004e3f7d60b.tar.gz
config: fix suggestion for failed set of multi-valued option
The command "git config set <name> <value>" fails for an option that has multiple values. List the "git config set" flags that can be used, instead of old-style "git config" actions. Reported-by: Paul Wintz <pwintz@ucsc.edu> Signed-off-by: René Scharfe <l.s.r@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--builtin/config.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/config.c b/builtin/config.c
index 59fb113b07..ef1c1a9cf2 100644
--- a/builtin/config.c
+++ b/builtin/config.c
@@ -974,7 +974,7 @@ static int cmd_config_set(int argc, const char **argv, const char *prefix,
argv[0], comment, value);
if (ret == CONFIG_NOTHING_SET)
error(_("cannot overwrite multiple values with a single value\n"
- " Use a regexp, --add or --replace-all to change %s."), argv[0]);
+ " Use --value=<pattern>, --append or --all to change %s."), argv[0]);
}
location_options_release(&location_opts);