diff options
author | Junio C Hamano <junkio@cox.net> | 2006-12-19 01:28:15 -0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-12-19 01:51:51 -0800 |
commit | d4ebc36c5ee964592303c59260417b758d024c31 (patch) | |
tree | d26506bdce4e91e5eb0df875e8661fa6ac8992df /builtin-repo-config.c | |
parent | 75c384efb52d0e3eb1e8c2f53668b4066fe6a8d6 (diff) | |
download | git-d4ebc36c5ee964592303c59260417b758d024c31.tar.gz |
Use preprocessor constants for environment variable names.
We broke the discipline Linus set up to allow compiler help us
avoid typos in environment names in the early days of git over
time. This defines a handful preprocessor constants for
environment variable names used in relatively core parts of the
system.
I've left out variable names specific to subsystems such as HTTP
and SSL as I do not think they are big problems.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'builtin-repo-config.c')
-rw-r--r-- | builtin-repo-config.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin-repo-config.c b/builtin-repo-config.c index a38099a63d..4885930ca4 100644 --- a/builtin-repo-config.c +++ b/builtin-repo-config.c @@ -67,10 +67,10 @@ static int get_value(const char* key_, const char* regex_) char *global = NULL, *repo_config = NULL; const char *local; - local = getenv("GIT_CONFIG"); + local = getenv(CONFIG_ENVIRONMENT); if (!local) { const char *home = getenv("HOME"); - local = getenv("GIT_CONFIG_LOCAL"); + local = getenv(CONFIG_LOCAL_ENVIRONMENT); if (!local) local = repo_config = xstrdup(git_path("config")); if (home) |