diff options
author | Joey Hess <joey@kitenet.net> | 2013-01-06 14:29:01 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-01-06 14:29:01 -0400 |
commit | a6cd089cea9b2e6d12461f02ca7fbef9b12d403c (patch) | |
tree | 5a6ed63807b8b012f42f8f8f2ab6da5e5883d342 /Remote/Rsync.hs | |
parent | 3bac971ac22afd706d7ad52013c86a7dae80c684 (diff) |
Fix transferring files to special remotes in direct mode.
Diffstat (limited to 'Remote/Rsync.hs')
-rw-r--r-- | Remote/Rsync.hs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Remote/Rsync.hs b/Remote/Rsync.hs index b05753830..9a38e4f1b 100644 --- a/Remote/Rsync.hs +++ b/Remote/Rsync.hs @@ -101,14 +101,14 @@ rsyncUrls o k = map use annexHashes f = keyFile k store :: RsyncOpts -> Key -> AssociatedFile -> MeterUpdate -> Annex Bool -store o k _f p = rsyncSend o p k <=< inRepo $ gitAnnexLocation k +store o k _f p = sendAnnex k $ rsyncSend o p k storeEncrypted :: RsyncOpts -> (Cipher, Key) -> Key -> MeterUpdate -> Annex Bool -storeEncrypted o (cipher, enck) k p = withTmp enck $ \tmp -> do - src <- inRepo $ gitAnnexLocation k - liftIO $ encrypt cipher (feedFile src) $ - readBytes $ L.writeFile tmp - rsyncSend o p enck tmp +storeEncrypted o (cipher, enck) k p = withTmp enck $ \tmp -> + sendAnnex k $ \src -> do + liftIO $ encrypt cipher (feedFile src) $ + readBytes $ L.writeFile tmp + rsyncSend o p enck tmp retrieve :: RsyncOpts -> Key -> AssociatedFile -> FilePath -> Annex Bool retrieve o k _ f = untilTrue (rsyncUrls o k) $ \u -> rsyncRemote o Nothing |