From 873823f39275ceb8d65ebfae74206c7347e07123 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Sun, 8 Feb 2015 21:47:55 -0500 Subject: BF: run commit hook with repo.working_dir as cwd Otherwise commit hook might rightfully fail, as happens if repository is e.g. git-annex repository. See e.g. now failing https://travis-ci.org/datalad/datalad/builds/49802394\#L1590 which seems to pass tests nicely with patch as this --- git/index/fun.py | 1 + 1 file changed, 1 insertion(+) (limited to 'git/index/fun.py') diff --git a/git/index/fun.py b/git/index/fun.py index f07cf7dc..c2fe912e 100644 --- a/git/index/fun.py +++ b/git/index/fun.py @@ -72,6 +72,7 @@ def run_commit_hook(name, index): env=env, stdout=subprocess.PIPE, stderr=subprocess.PIPE, + cwd=index.repo.working_dir, close_fds=(os.name == 'posix')) stdout, stderr = cmd.communicate() cmd.stdout.close() -- cgit v1.2.1