File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -175,7 +175,7 @@ main = hakyll $ do
175175 route idRoute
176176 compile $ do
177177 sponsors <- buildBoilerplateCtx (Just " Haskell Interlude" )
178- ctx <- podcastCtx <$> loadAll (" podcast/*/index.markdown" .&&. hasVersion " raw" )
178+ ctx <- podcastCtx . sortOn podcastOrd <$> loadAll (" podcast/*/index.markdown" .&&. hasVersion " raw" )
179179
180180 makeItem " "
181181 >>= loadAndApplyTemplate " templates/podcast/list.html" ctx
@@ -212,7 +212,7 @@ main = hakyll $ do
212212 route idRoute
213213 compile $ do
214214 sponsors <- buildBoilerplateCtx (Just " Haskell Foundation" )
215- podcastsCtx <- podcastCtx . take 1 . reverse <$> loadAll (" podcast/*/index.markdown" .&&. hasVersion " raw" )
215+ podcastsCtx <- podcastCtx . take 1 . reverse . sortOn podcastOrd <$> loadAll (" podcast/*/index.markdown" .&&. hasVersion " raw" )
216216 careersCtx <- careersCtx . reverse <$> loadAll " careers/*.markdown"
217217
218218 makeItem " "
@@ -386,6 +386,9 @@ podcastCtx episodes =
386386 listField " episodes" defaultContext (return $ reverse episodes) <>
387387 defaultContext
388388
389+ podcastOrd :: Item String -> Integer
390+ podcastOrd = read . head . fromJust . capture " podcast/*/index.markdown" . itemIdentifier
391+
389392-- careers ---------------------------------------------------------------------------------------------
390393careersCtx :: [Item String ] -> Context String
391394careersCtx reqs =
You can’t perform that action at this time.
0 commit comments