summaryrefslogtreecommitdiff
path: root/config.c
diff options
context:
space:
mode:
authorLibravatar Nguyễn Thái Ngọc Duy <pclouds@gmail.com>2018-07-21 09:49:19 +0200
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-07-23 11:19:09 -0700
commit1a07e59c3e269418f3f5d186d166bf5ab5db6667 (patch)
treeaf7144a561d023b0d095c6c5463d00fe05248be6 /config.c
parentSecond batch for 2.19 cycle (diff)
downloadtgif-1a07e59c3e269418f3f5d186d166bf5ab5db6667.tar.xz
Update messages in preparation for i18n
Many messages will be marked for translation in the following commits. This commit updates some of them to be more consistent and reduce diff noise in those commits. Changes are - keep the first letter of die(), error() and warning() in lowercase - no full stop in die(), error() or warning() if it's single sentence messages - indentation - some messages are turned to BUG(), or prefixed with "BUG:" and will not be marked for i18n - some messages are improved to give more information - some messages are broken down by sentence to be i18n friendly (on the same token, combine multiple warning() into one big string) - the trailing \n is converted to printf_ln if possible, or deleted if not redundant - errno_errno() is used instead of explicit strerror() Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'config.c')
-rw-r--r--config.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/config.c b/config.c
index f4a208a166..a57e3056ef 100644
--- a/config.c
+++ b/config.c
@@ -461,7 +461,7 @@ int git_config_from_parameters(config_fn_t fn, void *data)
envw = xstrdup(env);
if (sq_dequote_to_argv(envw, &argv, &nr, &alloc) < 0) {
- ret = error("bogus format in " CONFIG_DATA_ENVIRONMENT);
+ ret = error("bogus format in %s", CONFIG_DATA_ENVIRONMENT);
goto out;
}
@@ -1411,8 +1411,8 @@ static int git_default_push_config(const char *var, const char *value)
push_default = PUSH_DEFAULT_CURRENT;
else {
error("malformed value for %s: %s", var, value);
- return error("Must be one of nothing, matching, simple, "
- "upstream or current.");
+ return error("must be one of nothing, matching, simple, "
+ "upstream or current");
}
return 0;
}