projects
/
thetarpit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0be7583
)
site: compile images
author
Lucian Mogosanu
<lucian.mogosanu@gmail.com>
Thu, 25 Jul 2013 09:33:52 +0000
(12:33 +0300)
committer
Lucian Mogosanu
<lucian.mogosanu@gmail.com>
Thu, 25 Jul 2013 09:33:52 +0000
(12:33 +0300)
site.hs
patch
|
blob
|
history
diff --git
a/site.hs
b/site.hs
index
0aeb143
..
0f9a4b6
100644
(file)
--- a/
site.hs
+++ b/
site.hs
@@
-15,6
+15,7
@@
main = hakyllWith tarpitConfiguration $ do
match "index.html" compileIndex
match "css/*" compileCss
match "posts/*" $ compilePosts tags
+ match "images/*" $ compileImages
match (fromList pages) compilePages
create ["archive.html"] compileArchive
@@
-57,6
+58,11
@@
compilePosts tags = do
>>= loadAndApplyTemplate "templates/default.html" ctx
>>= relativizeUrls
+compileImages :: Rules ()
+compileImages = do
+ route idRoute
+ compile copyFileCompiler
+
compilePages :: Rules ()
compilePages = do
route $ setExtension "html"