aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgit-commit-script2
1 files changed, 1 insertions, 1 deletions
diff --git a/git-commit-script b/git-commit-script
index 42ee399bc..e818d0a35 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