convert listImportableContents to throwing exceptions
This commit is contained in:
parent
5d8e4a7c74
commit
e1ac42be77
8 changed files with 27 additions and 27 deletions
|
@ -337,8 +337,8 @@ removeExportLocation topdir loc =
|
|||
mkExportLocation loc'
|
||||
in go (upFrom loc') =<< tryIO (removeDirectory p)
|
||||
|
||||
listImportableContentsM :: RawFilePath -> Annex (Maybe (ImportableContents (ContentIdentifier, ByteSize)))
|
||||
listImportableContentsM dir = catchMaybeIO $ liftIO $ do
|
||||
listImportableContentsM :: RawFilePath -> Annex (ImportableContents (ContentIdentifier, ByteSize))
|
||||
listImportableContentsM dir = liftIO $ do
|
||||
l <- dirContentsRecursive (fromRawFilePath dir)
|
||||
l' <- mapM (go . toRawFilePath) l
|
||||
return $ ImportableContents (catMaybes l') []
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue