From: Alexey Guzeev <aga@supplehost.com>
Date: Wed, 1 Jun 2005 04:31:02 +0000 (-0400)
Subject: [PATCH] git: git-commit-script ignores $GIT_DIR
X-Git-Tag: v0.99~395
X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/ef6a46e6eaae5e70df8b7ef9d7ead66c3313027e

[PATCH] git: git-commit-script ignores $GIT_DIR
---

diff --git a/git-commit-script b/git-commit-script
index 42ee399bc1..e818d0a35c 100755
--- a/git-commit-script
+++ b/git-commit-script
@@ -10,4 +10,4 @@ grep -v '^#' < .editmsg | git-stripspace > .cmitmsg
 [ -s .cmitmsg ] || exit 1
 tree=$(git-write-tree) || exit 1
 commit=$(cat .cmitmsg | git-commit-tree $tree -p HEAD) || exit 1
-echo $commit > .git/HEAD
+echo $commit > ${GIT_DIR:-.git}/HEAD