2021-11-05 21:57:15 +00:00
|
|
|
module GHCup.Prelude.Windows where
|
2021-10-17 18:39:49 +00:00
|
|
|
|
|
|
|
|
import qualified System.Win32.File as Win32
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
isWindows, isNotWindows :: Bool
|
|
|
|
|
isWindows = True
|
|
|
|
|
isNotWindows = not isWindows
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
moveFile :: FilePath -> FilePath -> IO ()
|
|
|
|
|
moveFile from to = Win32.moveFileEx from (Just to) 0
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
moveFilePortable :: FilePath -> FilePath -> IO ()
|
|
|
|
|
moveFilePortable = Win32.moveFile
|
|
|
|
|
|