diff --git a/projects.md b/projects.md index 1d77be9..b9314eb 100644 --- a/projects.md +++ b/projects.md @@ -8,21 +8,21 @@ layout: post This project aims to help life scientists in managing their data - like a personal Google for your scientific data. It is the place where I apply newly learned skills to a real-world project. -You can find out more on [GitHub](https://github.com/peri4n/beagle) +You can find out more on [GitHub](https://github.com/peri4n/beagle){target="_blank"} # My Dev Environment Notorious for being a productivity nerd, it comes naturally that I care a lot about my development setup. I have customized my: -* Shell +* [Shell](https://github.com/peri4n/suckless-terminal){target="_blank"} * Editor (NeoVim) -* Window Manager +* [Window Manager](https://github.com/peri4n/wm){target="_blank"} * Email setup -* [Keyboard](https://github.com/peri4n/qmk_firmware) +* [Keyboard](https://github.com/peri4n/qmk_firmware){target="_blank"} Additionally applying all the customizations is automated using Ansible scripts. -You can find out more on [GitHub](https://github.com/peri4n/setup) +You can find out more on [GitHub](https://github.com/peri4n/setup){target="_blank"} # This Blog diff --git a/site.hs b/site.hs index cd4205f..c06a18e 100644 --- a/site.hs +++ b/site.hs @@ -33,6 +33,23 @@ main = do -- Process tags tags <- buildTags postsPattern (fromCapture "tags/*.html") + + -- Process articles + match postsPattern $ do + route $ setExtension "html" + compile $ pandocCompiler + >>= loadAndApplyTemplate "templates/post.html" (postCtxWithTags tags) + >>= loadAndApplyTemplate "templates/default.html" (postCtxWithTags tags) + >>= relativizeUrls + + match (fromList ["projects.md", "contact.md", "about.md"]) $ do + route $ setExtension "html" + compile $ pandocCompiler + >>= loadAndApplyTemplate "templates/page.html" pageCtx + >>= loadAndApplyTemplate "templates/default.html" pageCtx + >>= relativizeUrls + + -- Process tags pages tagsRules tags $ \tag pattern -> do let title = "Posts tagged \"" ++ tag ++ "\"" route idRoute @@ -46,13 +63,6 @@ main = do >>= loadAndApplyTemplate "templates/default.html" ctx >>= relativizeUrls - -- Process articles - match (postsPattern .||. fromList ["projects.md", "contact.md", "about.md"]) $ do - route $ setExtension "html" - compile $ pandocCompiler - >>= loadAndApplyTemplate "templates/post.html" (postCtxWithTags tags) - >>= loadAndApplyTemplate "templates/default.html" (postCtxWithTags tags) - >>= relativizeUrls -- Process index page match "index.html" $ do diff --git a/templates/default.html b/templates/default.html index 7e030f2..fda2780 100644 --- a/templates/default.html +++ b/templates/default.html @@ -6,6 +6,7 @@ $if(metaKeywords)$$metaKeywords$$endif$ $title$ + diff --git a/templates/page.html b/templates/page.html new file mode 100644 index 0000000..72745e8 --- /dev/null +++ b/templates/page.html @@ -0,0 +1,18 @@ +
+ + +
+
+ $title$ + + by $author$ on $date$ + +
+
+ $body$ +
+ +
+
diff --git a/templates/post.html b/templates/post.html index 8038137..66cda6e 100644 --- a/templates/post.html +++ b/templates/post.html @@ -1,19 +1,11 @@
-