add file-io to build-depends when building with OsPath flag
Partly converted code to use functions from it, though more remain unconverted. Most of withFile and openFile now use it.
This commit is contained in:
parent
85efc13e3a
commit
1faa3af9cd
20 changed files with 178 additions and 68 deletions
|
@ -45,6 +45,7 @@ import qualified Database.Fsck as FsckDb
|
|||
import Types.CleanupActions
|
||||
import Types.Key
|
||||
import qualified Utility.RawFilePath as R
|
||||
import qualified Utility.FileIO as F
|
||||
|
||||
import Data.Time.Clock.POSIX
|
||||
import System.Posix.Types (EpochTime)
|
||||
|
@ -678,7 +679,7 @@ recordStartTime u = do
|
|||
f <- fromRepo (gitAnnexFsckState u)
|
||||
createAnnexDirectory $ parentDir f
|
||||
liftIO $ removeWhenExistsWith R.removeLink f
|
||||
liftIO $ withFile (fromRawFilePath f) WriteMode $ \h -> do
|
||||
liftIO $ F.withFile (toOsPath f) WriteMode $ \h -> do
|
||||
#ifndef mingw32_HOST_OS
|
||||
t <- modificationTime <$> R.getFileStatus f
|
||||
#else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue