From 02f1bd2bf47d3ff49a222e9428ec27708ef55f64 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 14 Dec 2011 15:30:14 -0400 Subject: split more stuff out of Git.hs --- Annex/Ssh.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Annex/Ssh.hs') diff --git a/Annex/Ssh.hs b/Annex/Ssh.hs index 6893f94ef..fe83aad00 100644 --- a/Annex/Ssh.hs +++ b/Annex/Ssh.hs @@ -10,6 +10,7 @@ module Annex.Ssh where import Control.Monad.State (liftIO) import qualified Git +import qualified Git.Url import Utility.SafeCommand import Types import Config @@ -22,10 +23,10 @@ sshToRepo :: Git.Repo -> [CommandParam] -> Annex [CommandParam] sshToRepo repo sshcmd = do s <- getConfig repo "ssh-options" "" let sshoptions = map Param (words s) - let sshport = case Git.urlPort repo of + let sshport = case Git.Url.port repo of Nothing -> [] Just p -> [Param "-p", Param (show p)] - let sshhost = Param $ Git.urlHostUser repo + let sshhost = Param $ Git.Url.hostuser repo return $ sshoptions ++ sshport ++ [sshhost] ++ sshcmd {- Generates parameters to run a git-annex-shell command on a remote -- cgit v1.2.3