[PATCH] Make gitk work when launched in a subdirectory
authorPeter Baumann <siprbaum@stud.informatik.uni-erlangen.de>
Tue, 9 Jan 2007 14:30:19 +0000 (15:30 +0100)
committerPaul Mackerras <paulus@samba.org>
Sat, 13 Jan 2007 05:15:09 +0000 (16:15 +1100)
Make gitk use git-rev-parse --git-dir to find the repository.

Signed-off-by: Peter Baumann <siprbaum@stud.informatik.uni-erlangen.de>
Signed-off-by: Paul Mackerras <paulus@samba.org>
gitk

diff --git a/gitk b/gitk
index 33bac1f3f6ff74cda79e31589d855d62eb5cdaf8..031c829f267d5926ebdf689fea1d8cc1c79cb141 100755 (executable)
--- a/gitk
+++ b/gitk
@@ -12,7 +12,7 @@ proc gitdir {} {
     if {[info exists env(GIT_DIR)]} {
        return $env(GIT_DIR)
     } else {
-       return ".git"
+       return [exec git rev-parse --git-dir]
     }
 }