git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Use git-rev-parse --git-dir to determine GIT_DIR
@ 2006-11-30 16:45 Peter Baumann
  0 siblings, 0 replies; only message in thread
From: Peter Baumann @ 2006-11-30 16:45 UTC (permalink / raw)
  To: git; +Cc: Paul Mackerras

Signed-off-by: Peter Baumann <siprbaum@stud.informatik.uni-erlangen.de>
---
 gitk |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/gitk b/gitk
index ab383b3..60f8212 100755
--- a/gitk
+++ b/gitk
@@ -8,12 +8,7 @@ exec wish "$0" -- "$@"
 # either version 2, or (at your option) any later version.
 
 proc gitdir {} {
-    global env
-    if {[info exists env(GIT_DIR)]} {
-	return $env(GIT_DIR)
-    } else {
-	return ".git"
-    }
+    return [exec git rev-parse --git-dir]
 }
 
 proc start_rev_list {view} {
-- 
1.4.3.3

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2006-11-30 16:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-30 16:45 [PATCH] Use git-rev-parse --git-dir to determine GIT_DIR Peter Baumann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).