aboutsummaryrefslogtreecommitdiff
path: root/environment.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-05-05 19:16:16 -0700
committerJunio C Hamano <gitster@pobox.com>2008-05-05 19:16:16 -0700
commite2e2defc14a79ea5b4aaae23e33072f29c5965eb (patch)
tree6a86523e0105c66bef7e7ee8610773d185b7cad3 /environment.c
parent9c36e1700f99811ea9190279ea197424dcbb0303 (diff)
parentc48799e560c826905e87c8a8a71effeb0ca5e897 (diff)
downloadgit-e2e2defc14a79ea5b4aaae23e33072f29c5965eb.tar.xz
Merge branch 'lh/git-file'
* lh/git-file: Teach GIT-VERSION-GEN about the .git file Teach git-submodule.sh about the .git file Teach resolve_gitlink_ref() about the .git file Add platform-independent .git "symlink"
Diffstat (limited to 'environment.c')
-rw-r--r--environment.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/environment.c b/environment.c
index 6739a3f417..fcd1ee5ef8 100644
--- a/environment.c
+++ b/environment.c
@@ -50,6 +50,8 @@ static void setup_git_env(void)
{
git_dir = getenv(GIT_DIR_ENVIRONMENT);
if (!git_dir)
+ git_dir = read_gitfile_gently(DEFAULT_GIT_DIR_ENVIRONMENT);
+ if (!git_dir)
git_dir = DEFAULT_GIT_DIR_ENVIRONMENT;
git_object_dir = getenv(DB_ENVIRONMENT);
if (!git_object_dir) {