simiweb/Main.hs

32 lines
713 B
Haskell
Raw Normal View History

2024-01-31 16:20:02 +01:00
{-# LANGUAGE OverloadedStrings #-}
import qualified GHC.IO.Encoding as E
import Data.Monoid (mappend)
import Hakyll
main :: IO ()
main = do
E.setLocaleEncoding E.utf8
hakyll $ do
match "assets/css/*" $ do
route idRoute
compile compressCssCompiler
match "assets/images/*" $ do
route idRoute
compile copyFileCompiler
{-match "index.md" $ do
route $ setExtension "html"
compile $ pandocCompiler
>>= loadAndApplyTemplate "layouts/default.html" defaultContext
>>= relativizeUrls-}
match "index.html" $ do
route $ idRoute
compile $ getResourceBody
>>= relativizeUrls
match "layouts/*" $ compile templateBodyCompiler