diff options
author | Joey Hess <joey@kitenet.net> | 2013-06-17 22:05:49 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-06-17 22:05:49 -0400 |
commit | a659c68cc24731e150244980663a78a7a15bb530 (patch) | |
tree | 07d9426790922ea0bc3a82cc2f1fea750338c189 /Annex | |
parent | 830781033b8a36e77dcd9ae8eda83cde02e500fc (diff) |
Windows: Ssh connection caching is now supported.
Turns out the socket stuff just works on windows.
Diffstat (limited to 'Annex')
-rw-r--r-- | Annex/Ssh.hs | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/Annex/Ssh.hs b/Annex/Ssh.hs index 940cbb5a7..99b3c4435 100644 --- a/Annex/Ssh.hs +++ b/Annex/Ssh.hs @@ -63,18 +63,16 @@ sshInfo (host, port) = go =<< sshCacheDir , Params "-o ControlMaster=auto -o ControlPersist=yes" ] -{- ssh connection caching creates sockets, so will not work on a - - crippled filesystem. A GIT_ANNEX_TMP_DIR can be provided to use +{- ssh connection caching creates sockets, so will not work on all file + - systems. A GIT_ANNEX_TMP_DIR can be provided to use - a different filesystem. -} sshCacheDir :: Annex (Maybe FilePath) sshCacheDir - | SysConfig.sshconnectioncaching = ifM crippledFileSystem - ( maybe (return Nothing) usetmpdir =<< gettmpdir - , ifM (fromMaybe True . annexSshCaching <$> Annex.getGitConfig) + | SysConfig.sshconnectioncaching = + ifM (fromMaybe True . annexSshCaching <$> Annex.getGitConfig) ( Just <$> fromRepo gitAnnexSshDir - , return Nothing + , maybe (return Nothing) usetmpdir =<< gettmpdir ) - ) | otherwise = return Nothing where gettmpdir = liftIO $ getEnv "GIT_ANNEX_TMP_DIR" |