hakyll 3.1.2.0 → 3.1.2.1
raw patch · 2 files changed
+9/−4 lines, 2 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- hakyll.cabal +1/−1
- src/Hakyll/Core/Run.hs +8/−3
hakyll.cabal view
@@ -1,5 +1,5 @@ Name: hakyll-Version: 3.1.2.0+Version: 3.1.2.1 Synopsis: A simple static site generator library. Description: A simple static site generator library, mainly aimed at
src/Hakyll/Core/Run.hs view
@@ -46,8 +46,9 @@ provider <- timed logger "Creating provider" $ fileResourceProvider configuration - -- Fetch the old graph from the store- oldGraph <- fromMaybe mempty <$>+ -- Fetch the old graph from the store. If we don't find it, we consider this+ -- to be the first run+ (firstRun, oldGraph) <- fromMaybe (True, mempty) . fmap ((,) False) <$> storeGet store "Hakyll.Core.Run.run" "dependencies" let ruleSet = runRules rules provider@@ -61,6 +62,7 @@ , hakyllRoutes = rulesRoutes ruleSet , hakyllResourceProvider = provider , hakyllStore = store+ , hakyllFirstRun = firstRun } -- Run the program and fetch the resulting state@@ -83,6 +85,7 @@ , hakyllRoutes :: Routes , hakyllResourceProvider :: ResourceProvider , hakyllStore :: Store+ , hakyllFirstRun :: Bool } data RuntimeState = RuntimeState@@ -105,6 +108,7 @@ section logger "Adding new compilers" provider <- hakyllResourceProvider <$> ask store <- hakyllStore <$> ask+ firstRun <- hakyllFirstRun <$> ask -- Old state information oldCompilers <- hakyllCompilers <$> get@@ -124,9 +128,10 @@ -- Check which items have been modified modified <- fmap S.fromList $ flip filterM (map fst newCompilers) $ liftIO . resourceModified provider store . fromIdentifier+ let checkModified = if firstRun then const True else (`S.member` modified) -- Create a new analyzer and append it to the currect one- let newAnalyzer = makeDependencyAnalyzer newGraph (`S.member` modified) $+ let newAnalyzer = makeDependencyAnalyzer newGraph checkModified $ analyzerPreviousGraph oldAnalyzer analyzer = mappend oldAnalyzer newAnalyzer