finish fixing removeLink on windows
9cb250f7be
got the ones in RawFilePath,
but there were others that used the one from unix-compat, which fails at
runtime on windows. To avoid this,
import System.PosixCompat.Files hiding removeLink
This commit was sponsored by Ethan Aubin.
This commit is contained in:
parent
dce0781391
commit
a3b714ddd9
28 changed files with 73 additions and 64 deletions
|
@ -49,9 +49,9 @@ import Git.FilePath
|
|||
import Annex.InodeSentinal
|
||||
import Annex.AdjustedBranch
|
||||
import Annex.FileMatcher
|
||||
import qualified Utility.RawFilePath as R
|
||||
|
||||
import Control.Exception (IOException)
|
||||
import qualified Utility.RawFilePath as R
|
||||
|
||||
data LockedDown = LockedDown
|
||||
{ lockDownConfig :: LockDownConfig
|
||||
|
@ -113,7 +113,7 @@ lockDown' cfg file = tryIO $ ifM crippledFileSystem
|
|||
(tmpfile, h) <- openTempFile (fromRawFilePath tmpdir) $
|
||||
relatedTemplate $ "ingest-" ++ takeFileName file
|
||||
hClose h
|
||||
removeWhenExistsWith removeLink tmpfile
|
||||
removeWhenExistsWith R.removeLink (toRawFilePath tmpfile)
|
||||
withhardlink' delta tmpfile
|
||||
`catchIO` const (nohardlink' delta)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue