summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorChris Wells <chris@mathematicaster.org>2026-02-08 20:34:13 -0600
committerChris Wells <chris@mathematicaster.org>2026-02-08 20:34:13 -0600
commit2df49f63b4e5095ff3fbe31d61a78302981cbe95 (patch)
tree267e973292d313bc374913b0d855403f47ca669a /app
parentff65b3f82a5cdb84ef528ca9265d908c55f48902 (diff)
downloadmain-2df49f63b4e5095ff3fbe31d61a78302981cbe95.tar
main-2df49f63b4e5095ff3fbe31d61a78302981cbe95.tar.gz
main-2df49f63b4e5095ff3fbe31d61a78302981cbe95.tar.bz2
main-2df49f63b4e5095ff3fbe31d61a78302981cbe95.tar.lz
main-2df49f63b4e5095ff3fbe31d61a78302981cbe95.tar.xz
main-2df49f63b4e5095ff3fbe31d61a78302981cbe95.tar.zst
main-2df49f63b4e5095ff3fbe31d61a78302981cbe95.zip
Making sure things compile properly
Diffstat (limited to 'app')
-rw-r--r--app/Main.hs31
1 files changed, 22 insertions, 9 deletions
diff --git a/app/Main.hs b/app/Main.hs
index bce890b..ec508d4 100644
--- a/app/Main.hs
+++ b/app/Main.hs
@@ -36,6 +36,9 @@ main = do
match "data/licenses.yaml" $ compile $ yamlCompiler @(AliasMap StrictText License_)
match "data/journals.yaml" $ compile $ yamlCompiler @(AliasMap StrictText Journal_)
+ -- load any snippets
+ match "**/_*.html" $ compile getResourceBody
+
match "assets/**" $ do
route $ dropParentRoute 1
compile copyFileCompiler
@@ -83,6 +86,7 @@ main = do
] -- Remove me from the author list
}
getResourceBody >>= applyAsTemplate (mkPaperContext (personCtxt "data/people.yaml" <> journalCtxt "data/journals.yaml") fixedPapers) >>= applyTemplate defaultTemplate baseCtxt
+
match "www/teaching/index.md" $ do
route $ dropParentRoute 1 `composeRoutes` setExtension ".html"
-- compile $ myPandocCompiler >>= applyAsTemplate baseCtxt >>= applyTemplate defaultTemplate baseCtxt
@@ -92,18 +96,27 @@ main = do
route $ dropParentRoute 1 `composeRoutes` setExtension ".html"
compile $ getResourceBody >>= applyAsTemplate baseCtxt >>= myRenderPandoc >>= applyTemplate defaultTemplate baseCtxt
- match "www/contact/*.html" $ do
- route $ dropParentRoute 1
- compile $ getResourceBody >>= applyAsTemplate baseCtxt >>= applyTemplate defaultTemplate baseCtxt
+ -- match "www/contact/*.html" $ do
+ -- route $ dropParentRoute 1
+ -- compile $ getResourceBody >>= applyAsTemplate baseCtxt >>= applyTemplate defaultTemplate baseCtxt
+ --
+ -- match "www/code/*.html" $ do
+ -- route $ dropParentRoute 1
+ -- compile $ getResourceBody >>= applyAsTemplate baseCtxt >>= applyTemplate defaultTemplate baseCtxt
+ --
+ -- match "www/credits/*.html" $ do
+ -- route $ dropParentRoute 1
+ -- compile $ myPandocCompiler >>= applyTemplate defaultTemplate baseCtxt
- match "www/code/*.html" $ do
+ -- compile any other html
+ match "www/**/*.html" $ do
route $ dropParentRoute 1
- compile $ getResourceBody >>= applyAsTemplate baseCtxt >>= applyTemplate defaultTemplate baseCtxt
+ compile $ getResourceBody >>= applyTemplate defaultTemplate baseCtxt
- match "www/credits/*.html" $ do
- route $ dropParentRoute 1
- compile $ myPandocCompiler >>= applyTemplate defaultTemplate baseCtxt
- pure ()
+ -- just copy anything else hanging around
+ match "www/**" $ do
+ route idRoute
+ compile copyFileCompiler
myPandocCompiler :: Compiler (Item String)