aboutsummaryrefslogtreecommitdiff
path: root/Remotes.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2011-01-07 01:14:27 -0400
committerGravatar Joey Hess <joey@kitenet.net>2011-01-07 01:14:27 -0400
commit71a8278f9caea8d3e52a5d43cb60125018ec31fa (patch)
tree554e6f76bed01f36923496dfa89319a3da963819 /Remotes.hs
parente29d2376937691a4170498b095191a6ffefc9875 (diff)
bugfix: Running `move --to` with a non-ssh remote failed.
Diffstat (limited to 'Remotes.hs')
-rw-r--r--Remotes.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/Remotes.hs b/Remotes.hs
index 5bb2efa55..2c8cdfdad 100644
--- a/Remotes.hs
+++ b/Remotes.hs
@@ -249,8 +249,11 @@ copyToRemote r key
| not $ Git.repoIsUrl r = do
g <- Annex.gitRepo
let keysrc = annexLocation g key
- let keydest = annexLocation r key
- liftIO $ copyFile keysrc keydest
+ -- run copy from perspective of remote
+ liftIO $ do
+ a <- Annex.new r []
+ Annex.eval a $ Core.getViaTmp key $ \f ->
+ liftIO $ copyFile keysrc f
| Git.repoIsSsh r = do
g <- Annex.gitRepo
let keysrc = annexLocation g key