diff options
author | Hécate <hecate+gitlab@glitchbra.in> | 2020-09-22 20:35:49 +0200 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2020-09-24 13:17:44 -0400 |
commit | 007940d2fa1ac4f8046989d4af1d088914612a78 (patch) | |
tree | 5d5d90d58f43b0a881e74e2c6a498f8b082602f7 | |
parent | 6d0ce0eb772bf69c57e14f30c16c606ab5035816 (diff) | |
download | haskell-007940d2fa1ac4f8046989d4af1d088914612a78.tar.gz |
Namespace the Hadrian linting rule for base
-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" |