summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorChris Wells <chris@mathematicaster.org>2026-02-08 20:44:46 -0600
committerChris Wells <chris@mathematicaster.org>2026-02-08 20:44:46 -0600
commita1482f14ce5e47e9e410512e4fdee5c17a7c5da7 (patch)
tree61afcd409f370bbeceeff43978ada8abe3cb894a /app
parent2df49f63b4e5095ff3fbe31d61a78302981cbe95 (diff)
downloadmain-a1482f14ce5e47e9e410512e4fdee5c17a7c5da7.tar
main-a1482f14ce5e47e9e410512e4fdee5c17a7c5da7.tar.gz
main-a1482f14ce5e47e9e410512e4fdee5c17a7c5da7.tar.bz2
main-a1482f14ce5e47e9e410512e4fdee5c17a7c5da7.tar.lz
main-a1482f14ce5e47e9e410512e4fdee5c17a7c5da7.tar.xz
main-a1482f14ce5e47e9e410512e4fdee5c17a7c5da7.tar.zst
main-a1482f14ce5e47e9e410512e4fdee5c17a7c5da7.zip
For now, just copied the open-access books webpage
Diffstat (limited to 'app')
-rw-r--r--app/Main.hs6
1 files changed, 6 insertions, 0 deletions
diff --git a/app/Main.hs b/app/Main.hs
index ec508d4..ea3ea01 100644
--- a/app/Main.hs
+++ b/app/Main.hs
@@ -17,6 +17,7 @@ import Hakyll.Aeson (yamlCompiler)
import Hakyll.Paper (papersCompiler, mkPaperContext, FieldContext (..))
import Hakyll.TeX.BibTeX (bibtexCompiler)
import Hakyll.Web.Sass
+import Hakyll.Web.Redirect (createRedirects)
import Text.Jasmine (minify)
import WWW.Base (baseHakyll, domain, myHakyllWriterOptions, myHakyllReaderOptions)
import WWW.Templates (myContext, defaultTemplate)
@@ -92,6 +93,11 @@ main = do
-- compile $ myPandocCompiler >>= applyAsTemplate baseCtxt >>= applyTemplate defaultTemplate baseCtxt
compile $ getResourceBody >>= applyAsTemplate baseCtxt >>= myRenderPandoc >>= applyTemplate defaultTemplate baseCtxt
+
+ createRedirects $
+ [ ("teaching/books/index.html", "/books/index.html")
+ ]
+
match "www/links/index.md" $ do
route $ dropParentRoute 1 `composeRoutes` setExtension ".html"
compile $ getResourceBody >>= applyAsTemplate baseCtxt >>= myRenderPandoc >>= applyTemplate defaultTemplate baseCtxt