From f167851628d1fa101ad7b64beb2b02106f0d42b9 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 23 Oct 2020 15:51:38 -0400 Subject: [PATCH] Revert "pass --git-dir, rather than changing cwd" This reverts commit c142696c587100b195accec4e9bfaa26cde73d48. It turns out it was not needed; 681313dfd4e840e6366f3c39eddd92f65d764188 fixed up the git dir, so setting cwd to it works ok. But worst, this commit broke the test suite massively. I don't understand how. git-annex get was failing. Very weirdly, git-annex find in a fresh clone of an annex repo, during autoinit, was displaying a side message -- but side messages are disabled when running find. --- Git/Config.hs | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/Git/Config.hs b/Git/Config.hs index db1bc3c19b..45cf4aa8fb 100644 --- a/Git/Config.hs +++ b/Git/Config.hs @@ -61,15 +61,10 @@ read' repo = go repo go _ = assertLocal repo $ error "internal" git_config d = withCreateProcess p (git_config' p) where - params = - [ "--git-dir" - , fromRawFilePath d - , "config" - , "--null" - , "--list" - ] + params = ["config", "--null", "--list"] p = (proc "git" params) - { env = gitEnv repo + { cwd = Just (fromRawFilePath d) + , env = gitEnv repo , std_out = CreatePipe } git_config' p _ (Just hout) _ pid = -- 2.30.2