aboutsummaryrefslogtreecommitdiff
path: root/Annex/Ssh.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2015-11-10 16:52:30 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2015-11-10 16:52:30 -0400
commitc64d99fcbfef09a4d6088c245bba80001eb6bf2d (patch)
tree33d4bb8b4998cc9494cbddd7c6a6c36b935fa89d /Annex/Ssh.hs
parent42863c94b1b1dd8d831555febbbbbba3e6a6de02 (diff)
assistant: Pass ssh-options through 3 more git pull/push calls that were missed before.
It was used for regular pull, but not for regular push, tagged push, or the fallback fetching.
Diffstat (limited to 'Annex/Ssh.hs')
-rw-r--r--Annex/Ssh.hs11
1 files changed, 6 insertions, 5 deletions
diff --git a/Annex/Ssh.hs b/Annex/Ssh.hs
index e92232b6f..9d716cdc8 100644
--- a/Annex/Ssh.hs
+++ b/Annex/Ssh.hs
@@ -263,9 +263,10 @@ inRepoWithSshOptionsTo remote gc a =
{- To make any git commands be run with ssh caching enabled,
- and configured ssh-options alters the local Git.Repo's gitEnv
- - to set GIT_SSH=git-annex, and sets sshOptionsEnv. -}
+ - to set GIT_SSH=git-annex, and set sshOptionsEnv when running git
+ - commands. -}
sshOptionsTo :: Git.Repo -> RemoteGitConfig -> Git.Repo -> Annex Git.Repo
-sshOptionsTo remote gc g
+sshOptionsTo remote gc localr
| not (Git.repoIsUrl remote) || Git.repoIsHttp remote = unchanged
| otherwise = case Git.Url.hostuser remote of
Nothing -> unchanged
@@ -277,7 +278,7 @@ sshOptionsTo remote gc g
prepSocket sockfile
use (sshConnectionCachingParams sockfile)
where
- unchanged = return g
+ unchanged = return localr
use opts = do
let sshopts = concat
@@ -289,9 +290,9 @@ sshOptionsTo remote gc g
else do
command <- liftIO programPath
liftIO $ do
- g' <- addGitEnv g sshOptionsEnv
+ localr' <- addGitEnv localr sshOptionsEnv
(toSshOptionsEnv sshopts)
- addGitEnv g' "GIT_SSH" command
+ addGitEnv localr' "GIT_SSH" command
runSshOptions :: [String] -> String -> IO ()
runSshOptions args s = do