summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: d33738d)
raw | patch | inline | side by side (parent: d33738d)
author | Jonathan Nieder <jrnieder@gmail.com> | |
Wed, 11 Nov 2009 23:57:36 +0000 (17:57 -0600) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Fri, 13 Nov 2009 20:16:30 +0000 (12:16 -0800) |
For scripts using "git var -l" to read all logical variables at
once, not all per-variable warnings will be relevant. So suppress
them.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
once, not all per-variable warnings will be relevant. So suppress
them.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
ident.c | patch | blob | history | |
var.c | patch | blob | history |
index 99f1c85ea5f5c83247f7affd3d801ff5c14393a6..26409b2a1b191765706265c2aa6d2ae163ba5bab 100644 (file)
--- a/ident.c
+++ b/ident.c
if ((warn_on_no_name || error_on_no_name) &&
name == git_default_name && env_hint) {
fprintf(stderr, env_hint, au_env, co_env);
- env_hint = NULL; /* warn only once, for "git var -l" */
+ env_hint = NULL; /* warn only once */
}
if (error_on_no_name)
die("empty ident %s <%s> not allowed", name, email);
index 125c0d1676abae6de29de14061d1a24fd842712d..dacbaab259e8ea81f20053f131ba609cf402cc61 100644 (file)
--- a/var.c
+++ b/var.c
{
struct git_var *ptr;
for (ptr = git_vars; ptr->read; ptr++)
- printf("%s=%s\n", ptr->name, ptr->read(IDENT_WARN_ON_NO_NAME));
+ printf("%s=%s\n", ptr->name, ptr->read(0));
}
static const char *read_var(const char *var)