summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Command/Move.hs13
-rw-r--r--debian/changelog4
2 files changed, 13 insertions, 4 deletions
diff --git a/Command/Move.hs b/Command/Move.hs
index 2f2cd1b5d..6b58f711a 100644
--- a/Command/Move.hs
+++ b/Command/Move.hs
@@ -120,10 +120,15 @@ fromStart src move file key
showMoveAction move file
next $ fromPerform src move key
fromOk :: Remote -> Key -> Annex Bool
-fromOk src key = do
- u <- getUUID
- remotes <- Remote.keyPossibilities key
- return $ u /= Remote.uuid src && any (== src) remotes
+fromOk src key
+ | Remote.hasKeyCheap src =
+ either (const expensive) return =<< Remote.hasKey src key
+ | otherwise = expensive
+ where
+ expensive = do
+ u <- getUUID
+ remotes <- Remote.keyPossibilities key
+ return $ u /= Remote.uuid src && any (== src) remotes
fromPerform :: Remote -> Bool -> Key -> CommandPerform
fromPerform src move key = moveLock move key $ do
ishere <- inAnnex key
diff --git a/debian/changelog b/debian/changelog
index 94bc09389..1d401149d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -36,6 +36,10 @@ git-annex (3.20120124) UNRELEASED; urgency=low
less frequently, when a merge or sync is done.
* configure: Check if ssh connection caching is supported by the installed
version of ssh and default annex.sshcaching accordingly.
+ * move --from, copy --from: Now 10 times faster when scanning to find
+ files in a remote on a local disk; rather than go through the location log
+ to see which files are present on the remote, it simply looks at the
+ disk contents directly.
-- Joey Hess <joeyh@debian.org> Tue, 24 Jan 2012 16:21:55 -0400