summaryrefslogtreecommitdiff
path: root/config.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2011-03-22 21:38:12 -0700
committerJunio C Hamano <gitster@pobox.com>2011-03-22 21:38:12 -0700
commit50aaeca008194854dcc90836edaff58b9be6e0fc (patch)
treee164971f944a45756841b17813f59ce345e31caa /config.c
parentf59bf09678ae33901febdf61e03c91bb8eebd970 (diff)
parent95a1d12e9b9faddc02187ca28fdeb4fddd354c59 (diff)
downloadgit-50aaeca008194854dcc90836edaff58b9be6e0fc.tar.gz
Merge branch 'jn/test-sanitize-git-env'
* jn/test-sanitize-git-env: tests: scrub environment of GIT_* variables config: drop support for GIT_CONFIG_NOGLOBAL gitattributes: drop support for GIT_ATTR_NOGLOBAL tests: suppress system gitattributes tests: stop worrying about obsolete environment variables
Diffstat (limited to 'config.c')
-rw-r--r--config.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/config.c b/config.c
index fa740a6a60..e28197a3f6 100644
--- a/config.c
+++ b/config.c
@@ -825,11 +825,6 @@ int git_config_system(void)
return !git_env_bool("GIT_CONFIG_NOSYSTEM", 0);
}
-int git_config_global(void)
-{
- return !git_env_bool("GIT_CONFIG_NOGLOBAL", 0);
-}
-
int git_config_from_parameters(config_fn_t fn, void *data)
{
static int loaded_environment;
@@ -861,7 +856,7 @@ int git_config_early(config_fn_t fn, void *data, const char *repo_config)
}
home = getenv("HOME");
- if (git_config_global() && home) {
+ if (home) {
char *user_config = xstrdup(mkpath("%s/.gitconfig", home));
if (!access(user_config, R_OK)) {
ret += git_config_from_file(fn, user_config, data);