about summary refs log tree commit diff
path: root/site.hs
diff options
context:
space:
mode:
authorPaweł Dybiec <pawel.to.malpa@gmail.com>2019-12-31 01:33:27 +0100
committerPaweł Dybiec <pawel.to.malpa@gmail.com>2019-12-31 01:33:27 +0100
commitcaef9bd707ea2f69275c70a1f187962196a76c5d (patch)
tree2e81a333f7dc477939c9e8b6d3f9bc6a0dc5ca2d /site.hs
parentIgnore hakyll directories (diff)
My css + removed some template stuff
Diffstat (limited to 'site.hs')
-rw-r--r--site.hs19
1 files changed, 13 insertions, 6 deletions
diff --git a/site.hs b/site.hs
index 210245c..b6c2724 100644
--- a/site.hs
+++ b/site.hs
@@ -11,15 +11,22 @@ main = hakyll $ do
         route   idRoute
         compile copyFileCompiler
 
-    match "css/*" $ do
+   {- match "css/*" $ do
         route   idRoute
-        compile compressCssCompiler
-
-    match (fromList ["about.md", "contact.md"]) $ do
+        compile compressCssCompiler -}
+    match "css/*" $ compile compressCssCompiler
+    create ["style.css"] $ do
+        route idRoute
+        compile $ do
+            csses <- loadAll "css/*.css"
+            makeItem $ unlines $ map itemBody csses
+    
+    match (fromList ["about.md"]) $ do
         route   $ setExtension "html"
         compile $ pandocCompiler
             >>= loadAndApplyTemplate "templates/default.html" defaultContext
             >>= relativizeUrls
+    
 
     match "posts/*" $ do
         route $ setExtension "html"
@@ -46,9 +53,9 @@ main = hakyll $ do
     match "index.html" $ do
         route idRoute
         compile $ do
-            posts <- recentFirst =<< loadAll "posts/*"
+            --posts <- recentFirst =<< loadAll "posts/*"
             let indexCtx =
-                    listField "posts" postCtx (return posts) `mappend`
+                    --listField "posts" postCtx (return posts) `mappend`
                     constField "title" "Home"                `mappend`
                     defaultContext