summaryrefslogtreecommitdiff
path: root/init.d
diff options
context:
space:
mode:
authorJoey Hess <joey@kodama.kitenet.net>2007-11-05 17:30:39 -0500
committerJoey Hess <joey@kodama.kitenet.net>2007-11-05 17:30:39 -0500
commitf0522c931958b7dccca733229254f2e37f0ef20c (patch)
tree01c3964078b47200e3d624dccd3dafa10d18311f /init.d
parentc01f3fe97eadce94a2f37908dc57f54d9af5b25a (diff)
support git commit being run in a subdir
Store the toplevel directory of the repo in the pre-commit hook, and cd to there. This is not ideal, but good enough.
Diffstat (limited to 'init.d')
-rwxr-xr-xinit.d/40git-pre-commit-hook2
1 files changed, 1 insertions, 1 deletions
diff --git a/init.d/40git-pre-commit-hook b/init.d/40git-pre-commit-hook
index cf96c1e..88eb581 100755
--- a/init.d/40git-pre-commit-hook
+++ b/init.d/40git-pre-commit-hook
@@ -10,7 +10,7 @@ else
# pre-commit hook for etckeeper. Calls etckeeper-pre-commit to store metadata
# and do sanity checks.
set -e
-etckeeper-pre-commit
+etckeeper-pre-commit `pwd`
EOF
chmod +x .git/hooks/pre-commit
fi