summaryrefslogtreecommitdiff
path: root/Annex/Content.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2015-01-06 19:00:01 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2015-01-06 19:00:01 -0400
commit6be8289158fd30d972ac22766452e7c9dc809e6f (patch)
treeba4929c7c8f27d2b43051f637394115cda39258b /Annex/Content.hs
parent6ea1214fa5d19241851a977ab82437563e2afc81 (diff)
parent971ed2a464a1a1e4d5e650e32390d232cd354d9d (diff)
Merge branch 'master' into relativepaths
Conflicts: Locations.hs debian/changelog
Diffstat (limited to 'Annex/Content.hs')
-rw-r--r--Annex/Content.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/Annex/Content.hs b/Annex/Content.hs
index 37090d3bb..2d52dcefb 100644
--- a/Annex/Content.hs
+++ b/Annex/Content.hs
@@ -261,7 +261,7 @@ finishGetViaTmp check key action = do
prepTmp :: Key -> Annex FilePath
prepTmp key = do
tmp <- fromRepo $ gitAnnexTmpObjectLocation key
- createAnnexDirectory (parentDir tmp)
+ createAnnexDirectory (takeDirectory tmp)
return tmp
{- Creates a temp file for a key, runs an action on it, and cleans up
@@ -425,7 +425,7 @@ cleanObjectLoc key cleaner = do
where
removeparents _ 0 = noop
removeparents file n = do
- let dir = parentDir file
+ let dir = takeDirectory file
maybe noop (const $ removeparents dir (n-1))
<=< catchMaybeIO $ removeDirectory dir
@@ -474,7 +474,7 @@ moveBad key = do
src <- calcRepo $ gitAnnexLocation key
bad <- fromRepo gitAnnexBadDir
let dest = bad </> takeFileName src
- createAnnexDirectory (parentDir dest)
+ createAnnexDirectory (takeDirectory dest)
cleanObjectLoc key $
liftIO $ moveFile src dest
logStatus key InfoMissing