2 module Main (main) where
4 import Control.Exception
6 import System.Directory
10 main = do tryIO $ removeFile to
11 cs_before <- getDirectoryContents "copyFile"
13 print $ sort cs_before
15 cs_before <- getDirectoryContents "copyFile"
17 print $ sort cs_before
20 tryIO :: IO a -> IO (Either IOException a)
24 from = "copyFile/source"
25 to = "copyFile/target"