i18n: factorize "invalid value" messages
Use the same message when an invalid value is passed to a command line option or a configuration variable. Signed-off-by: Jean-Noël Avila <jn.avila@free.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
a699367bb8
commit
1a8aea857e
3
setup.c
3
setup.c
@ -559,7 +559,8 @@ static enum extension_result handle_extension(const char *var,
|
||||
return config_error_nonbool(var);
|
||||
format = hash_algo_by_name(value);
|
||||
if (format == GIT_HASH_UNKNOWN)
|
||||
return error("invalid value for 'extensions.objectformat'");
|
||||
return error(_("invalid value for '%s': '%s'"),
|
||||
"extensions.objectformat", value);
|
||||
data->hash_algo = format;
|
||||
return EXTENSION_OK;
|
||||
}
|
||||
|
Reference in New Issue
Block a user