export a more generalized checkDiskSpace

This commit is contained in:
Joey Hess 2012-04-20 14:57:57 -04:00
parent c908bd3b97
commit 262017e17d
2 changed files with 24 additions and 24 deletions

View file

@ -34,8 +34,7 @@ start file (key, _) = do
perform :: FilePath -> Key -> CommandPerform
perform dest key = do
unlessM (inAnnex key) $ error "content not present"
checkDiskSpace key
unlessM (checkDiskSpace Nothing key 0) $ error "cannot unlock"
src <- inRepo $ gitAnnexLocation key
tmpdest <- fromRepo $ gitAnnexTmpLocation key