Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
bonnefoa committed Nov 30, 2010
1 parent b1bdf72 commit f32107f
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/Shaker/Action/Compile.hs
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,21 @@ import Shaker.Type

-- | Run haskell compilation on given CompileInput list
runCompile :: Plugin
runCompile = applyPreprocessSources >> asks shakerCompileInputs >>= foldM runUntilFail Succeeded >> return ()
runCompile = applyPreprocessSources
>> asks shakerCompileInputs
>>= foldM runUntilFail Succeeded
>> return ()

runUntilFail :: SuccessFlag -> CompileInput -> Shaker IO SuccessFlag
runUntilFail Succeeded cpIn = runSingleCompileInput cpIn
runUntilFail Failed _ = return Failed

-- | Run haskell compilation on all haskell files
runFullCompile :: Plugin
runFullCompile = applyPreprocessSources >> convertModuleDataToFullCompileInput >>= foldM runUntilFail Succeeded >> return()
runFullCompile = applyPreprocessSources
>> convertModuleDataToFullCompileInput
>>= foldM runUntilFail Succeeded
>> return()

runSingleCompileInput :: CompileInput -> Shaker IO SuccessFlag
runSingleCompileInput cplInp = do
Expand Down

0 comments on commit f32107f

Please sign in to comment.