diff options
author | guilhem <guilhem@fripost.org> | 2013-04-14 00:10:49 +0200 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-04-13 19:26:24 -0400 |
commit | 0957b771da4c58f593f3ecaf194ffdd5c6d335a5 (patch) | |
tree | 02043c5c8bd88ccae712cc84ccdae96175facd53 /Remote/Helper/Ssh.hs | |
parent | 371dfdfbebd7b7e5142f147324f67fce3ed9cce0 (diff) |
Allow rsync to use other remote shells.
Introduced a new per-remote option 'annex-rsync-transport' to specify
the remote shell that it to be used with rsync. In case the value is
'ssh', connections are cached unless 'sshcaching' is unset.
Diffstat (limited to 'Remote/Helper/Ssh.hs')
-rw-r--r-- | Remote/Helper/Ssh.hs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Remote/Helper/Ssh.hs b/Remote/Helper/Ssh.hs index 135b5c144..2e6b6d57c 100644 --- a/Remote/Helper/Ssh.hs +++ b/Remote/Helper/Ssh.hs @@ -22,9 +22,10 @@ sshToRepo :: Git.Repo -> [CommandParam] -> Annex [CommandParam] sshToRepo repo sshcmd = do g <- fromRepo id let c = extractRemoteGitConfig g (Git.repoDescribe repo) - let opts = map Param $ remoteAnnexSshOptions c - params <- sshParams (Git.Url.hostuser repo, Git.Url.port repo) opts - return $ params ++ sshcmd + opts = map Param $ remoteAnnexSshOptions c + host = Git.Url.hostuser repo + params <- sshCachingOptions (host, Git.Url.port repo) opts + return $ params ++ Param host : sshcmd {- Generates parameters to run a git-annex-shell command on a remote - repository. -} |