Permalink
Browse files

Remove all .hi files left.

  • Loading branch information...
1 parent e83fb23 commit 93b6da25a45abe79eac1e563fa73313afc883c75 @marcotmarcot committed Oct 11, 2012
Showing with 2 additions and 3 deletions.
  1. +2 −3 import-filter/test.hs
@@ -15,8 +15,7 @@ main
cleanModules :: IO ()
cleanModules
- = getDirectoryContents "."
- >>= mapM_ (removeFile . extension) . filter isModule
+ = getDirectoryContents "." >>= mapM_ removeFile . filter (".hi" `isSuffixOf`)
isModule :: FilePath -> Bool
isModule path = ".hs" `isSuffixOf` path && all isLetter path
@@ -39,7 +38,7 @@ testFile ok fail_ message file
(code, out, err)
<- readProcessWithExitCode "mptc" ["--make", file] ""
if code == ExitSuccess
- then removeFile (replaceExtension file ".hi") >> ok
+ then ok
else case message of
Nothing -> fail_
Just message_

0 comments on commit 93b6da2

Please sign in to comment.