|
|
|
@ -4,7 +4,6 @@ |
|
|
|
|
import Data.Monoid (mappend) |
|
|
|
|
import Hakyll |
|
|
|
|
import Hakyll.Web.Sass (sassCompiler) |
|
|
|
|
|
|
|
|
|
-------------------------------------------------------------------------------- |
|
|
|
|
config :: Configuration |
|
|
|
|
config = |
|
|
|
@ -14,11 +13,9 @@ config = |
|
|
|
|
|
|
|
|
|
main :: IO () |
|
|
|
|
main = hakyllWith config $ do |
|
|
|
|
match "images/*" $ do |
|
|
|
|
route idRoute |
|
|
|
|
compile copyFileCompiler |
|
|
|
|
-- Static directories |
|
|
|
|
|
|
|
|
|
match "files/*" $ do |
|
|
|
|
match ("fonts/*" .||. "images/*" .||. "files/*") $ do |
|
|
|
|
route idRoute |
|
|
|
|
compile copyFileCompiler |
|
|
|
|
|
|
|
|
@ -33,15 +30,7 @@ main = hakyllWith config $ do |
|
|
|
|
route idRoute |
|
|
|
|
compile compressCssCompiler |
|
|
|
|
|
|
|
|
|
match "posts/*" $ do |
|
|
|
|
route $ setExtension "html" |
|
|
|
|
compile $ |
|
|
|
|
pandocCompiler |
|
|
|
|
>>= loadAndApplyTemplate "templates/post.html" postCtx |
|
|
|
|
>>= loadAndApplyTemplate "templates/default.html" postCtx |
|
|
|
|
>>= relativizeUrls |
|
|
|
|
|
|
|
|
|
match "publications/*" $ do |
|
|
|
|
match ("posts/*" .||. "publications/*") $ do |
|
|
|
|
route $ setExtension "html" |
|
|
|
|
compile $ |
|
|
|
|
pandocCompiler |
|
|
|
|