summaryrefslogtreecommitdiff
path: root/Annex/Content.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-02-14 16:17:40 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-02-14 16:17:40 -0400
commit5fc9ccdaa5c73ec424de175962f98cc8fd63eca0 (patch)
tree1030a6fe9d351709bcdada518d4a24fa4986ed18 /Annex/Content.hs
parent177245deb6ee3271eb44d77c2b0cd722755b2c3f (diff)
split out Utility.InodeCache
Diffstat (limited to 'Annex/Content.hs')
-rw-r--r--Annex/Content.hs12
1 files changed, 6 insertions, 6 deletions
diff --git a/Annex/Content.hs b/Annex/Content.hs
index 0a66d9912..e488de274 100644
--- a/Annex/Content.hs
+++ b/Annex/Content.hs
@@ -260,7 +260,7 @@ moveAnnex key src = withObjectLoc key storeobject storedirect
storedirect' [] = storeobject =<< inRepo (gitAnnexLocation key)
storedirect' (dest:fs) = do
- updateCache key src
+ updateInodeCache key src
thawContent src
liftIO $ replaceFile dest $ moveFile src
liftIO $ forM_ fs $ \f -> replaceFile f $
@@ -308,10 +308,10 @@ prepSendAnnex key = withObjectLoc key indirect direct
indirect f = return $ Just (f, return True)
direct [] = return Nothing
direct (f:fs) = do
- cache <- recordedCache key
+ cache <- recordedInodeCache key
-- check that we have a good file
- ifM (compareCache f cache)
- ( return $ Just (f, compareCache f cache)
+ ifM (liftIO $ compareInodeCache f cache)
+ ( return $ Just (f, liftIO $ compareInodeCache f cache)
, direct fs
)
@@ -361,10 +361,10 @@ removeAnnex key = withObjectLoc key remove removedirect
liftIO $ removeFile file
cleanObjectLoc key
removedirect fs = do
- cache <- recordedCache key
+ cache <- recordedInodeCache key
mapM_ (resetfile cache) fs
cleanObjectLoc key
- resetfile cache f = whenM (compareCache f cache) $ do
+ resetfile cache f = whenM (liftIO $ compareInodeCache f cache) $ do
l <- calcGitLink f key
top <- fromRepo Git.repoPath
cwd <- liftIO getCurrentDirectory