diff options
-rw-r--r-- | hadrian/src/Rules/Lint.hs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/hadrian/src/Rules/Lint.hs b/hadrian/src/Rules/Lint.hs index bbecc08c31..39e047a4d4 100644 --- a/hadrian/src/Rules/Lint.hs +++ b/hadrian/src/Rules/Lint.hs @@ -7,21 +7,21 @@ import Settings.Builders.Common import System.Directory (findExecutable) lintRules :: Rules () -lintRules = "lint" ~> lint +lintRules = "lint:base" ~> lint base -lint :: Action () -lint = do +lint :: Action () -> Action () +lint lintAction = do isHlintPresent <- isJust <$> (liftIO $ findExecutable "hlint") if isHlintPresent then do putBuild "| Running the linter…" - lintBase + lintAction putSuccess "| Done." else putFailure "| Please make sure you have the `hlint` executable in your $PATH" -lintBase :: Action () -lintBase = do +base :: Action () +base = do topDir <- topDirectory buildDir <- buildRoot let stage1Lib = topDir </> buildDir </> "stage1/lib" |