diff options
author | Jasper Van der Jeugt <jaspervdj@gmail.com> | 2010-01-19 17:17:48 +0100 |
---|---|---|
committer | Jasper Van der Jeugt <jaspervdj@gmail.com> | 2010-01-19 17:17:48 +0100 |
commit | 0ba0eac8d96c11d13163c7ec184392513de7ca77 (patch) | |
tree | ca806e7fc8d8f049e251a4962136ce99fa2a004c /examples/morepages | |
parent | db0eef84705ebc25b3886cc94125dfebb84a45a0 (diff) | |
download | hakyll-0ba0eac8d96c11d13163c7ec184392513de7ca77.tar.gz |
Wrote another tutorial, and updated some tutorials.
Diffstat (limited to 'examples/morepages')
-rw-r--r-- | examples/morepages/about.markdown | 27 | ||||
-rw-r--r-- | examples/morepages/css/default.css | 27 | ||||
-rw-r--r-- | examples/morepages/footer.markdown | 16 | ||||
-rw-r--r-- | examples/morepages/hakyll.hs | 13 | ||||
-rw-r--r-- | examples/morepages/index.markdown | 24 | ||||
-rw-r--r-- | examples/morepages/products.markdown | 23 | ||||
-rw-r--r-- | examples/morepages/templates/default.html | 22 |
7 files changed, 152 insertions, 0 deletions
diff --git a/examples/morepages/about.markdown b/examples/morepages/about.markdown new file mode 100644 index 0000000..59d1aca --- /dev/null +++ b/examples/morepages/about.markdown @@ -0,0 +1,27 @@ +--- +title: About + +--- section1 +## Mattis +Nullam imperdiet sodales orci vitae molestie. Nunc quam orci, pharetra a +rhoncus vitae, eleifend id felis. Suspendisse potenti. Etiam vitae urna orci. +Quisque pellentesque dignissim felis, egestas tempus urna luctus vitae. In hac +habitasse platea dictumst. Morbi fringilla mattis odio, et mattis tellus +accumsan vitae. + +--- section2 +## Orci +Vivamus eget mauris sit amet nulla laoreet lobortis. Nulla in diam elementum +risus convallis commodo. Cras vehicula varius dui vitae facilisis. Proin +elementum libero eget leo aliquet quis euismod orci vestibulum. Duis rhoncus +lorem consequat tellus vestibulum aliquam. Quisque orci orci, malesuada porta +blandit et, interdum nec magna. + +--- section3 +## Augue +In urna ante, pulvinar et imperdiet nec, fermentum ac tortor. Cras tristique +pellentesque euismod. Pellentesque est ante, sagittis vitae vehicula vitae, +ullamcorper eget lectus. Curabitur egestas accumsan leo, ac ullamcorper nibh +tincidunt id. Curabitur lorem libero, fermentum non tincidunt ac, pretium in +libero. Donec vel mi eu tortor accumsan dictum ut in augue. Vestibulum est +lorem, bibendum eu vehicula eu, convallis eget mauris. diff --git a/examples/morepages/css/default.css b/examples/morepages/css/default.css new file mode 100644 index 0000000..0376cae --- /dev/null +++ b/examples/morepages/css/default.css @@ -0,0 +1,27 @@ +body { + width: 600px; + margin: 0px auto 0px auto; +} + +div#navigation { + text-align: center; + border-bottom: 4px solid black; +} + +div#navigation a { + color: white; + text-decoration: none; + background-color: black; + padding: 3px 10px 3px 10px; + margin: 0px 10px 0px 10px; +} + +div.column { + width: 30%; + float: left; + margin: 0px 10px 0px 10px; +} + +div#footer { + clear: both; +} diff --git a/examples/morepages/footer.markdown b/examples/morepages/footer.markdown new file mode 100644 index 0000000..408541c --- /dev/null +++ b/examples/morepages/footer.markdown @@ -0,0 +1,16 @@ +--- footer +## Sapien + +In hac habitasse platea dictumst. Cras placerat felis nec risus varius in +accumsan sem fermentum. Vestibulum elementum aliquam tortor semper vulputate. +Vivamus tincidunt tellus sed purus tempor fringilla. Morbi dui nisl, eleifend +non dictum vitae, luctus eu lacus. Duis vitae lacus sem, ut porta mauris. +Aenean sed ultricies dui. Vivamus ullamcorper metus lorem, at ornare nibh. +Mauris mi metus, convallis id lobortis vitae, interdum quis felis. Cras elit +massa, pellentesque sit amet pharetra ut, volutpat in arcu. Vivamus blandit, +ligula et ultricies consequat, metus sem congue quam, ac pretium enim velit at +tortor. Cras in tellus eu sapien pulvinar sollicitudin eu id ipsum. Mauris nec +urna tellus, et scelerisque tellus. Nunc imperdiet felis nec libero consectetur +tristique tristique ipsum sodales. Cras tortor nisl, condimentum in +pellentesque id, interdum vel mi. Suspendisse auctor vehicula orci at +scelerisque. Vivamus quis sagittis felis. diff --git a/examples/morepages/hakyll.hs b/examples/morepages/hakyll.hs new file mode 100644 index 0000000..a806042 --- /dev/null +++ b/examples/morepages/hakyll.hs @@ -0,0 +1,13 @@ +import Text.Hakyll (hakyll, defaultHakyllConfiguration) +import Text.Hakyll.File (directory) +import Text.Hakyll.Render (css, static, renderChain) +import Text.Hakyll.Renderables (createPagePath, combine) + +main = hakyll defaultHakyllConfiguration $ do + directory css "css" + render "about.markdown" + render "index.markdown" + render "products.markdown" + where + render = renderChain ["templates/default.html"] . withFooter . createPagePath + withFooter a = a `combine` createPagePath "footer.markdown" diff --git a/examples/morepages/index.markdown b/examples/morepages/index.markdown new file mode 100644 index 0000000..4a2dc80 --- /dev/null +++ b/examples/morepages/index.markdown @@ -0,0 +1,24 @@ +--- +title: Home + +--- section1 +## Purus +Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce tempor, urna et +auctor tincidunt, eros mauris facilisis purus, eget sollicitudin leo massa sit +amet ipsum. Vivamus eu massa in urna vehicula rutrum eget sit amet purus. + +--- section2 +## Ligula +Mauris sit amet justo mi. Curabitur vel quam felis. In hac habitasse platea +dictumst. Etiam nec consequat risus. Donec consequat est vitae neque fermentum +feugiat nec ac nibh. Nulla rhoncus, odio quis scelerisque rutrum, metus sem +tempor ante, a ornare ipsum felis sed ligula. Morbi urna lectus, scelerisque +non pharetra in, rutrum quis ligula. Phasellus semper ullamcorper arcu eu +auctor. + +--- section3 +## Justo +Aliquam sagittis tincidunt libero ut elementum. Ut sit amet vestibulum metus. +Ut aliquet congue neque eu tincidunt. Integer eu elit sed massa sollicitudin +vehicula nec ut sem. Cras euismod enim eget purus lacinia non feugiat urna +imperdiet. Aliquam justo sem, viverra eu vehicula vitae, imperdiet vel magna. diff --git a/examples/morepages/products.markdown b/examples/morepages/products.markdown new file mode 100644 index 0000000..7032479 --- /dev/null +++ b/examples/morepages/products.markdown @@ -0,0 +1,23 @@ +--- +title: Products + +--- section1 +## Lacus +Etiam condimentum auctor semper. Donec lobortis, magna id sodales sollicitudin, +lectus mi egestas nulla, pulvinar lobortis nunc eros id nisl. Curabitur +imperdiet, erat at accumsan vulputate, purus nunc blandit nulla, dictum +vestibulum sem lorem eget ipsum. + +--- section2 +## Vitae +Integer ut dui eu felis mollis vestibulum. Etiam at nibh id diam aliquet +vestibulum sit amet a nibh. Aliquam erat volutpat. Etiam vitae nulla at dolor +fringilla tempor ut a nunc. Pellentesque elementum elit lorem. Quisque nec +ligula ipsum. Nunc augue lacus, ullamcorper vel dapibus in, mattis eget elit. + +--- section3 +## Feugiat +Pellentesque enim dui, interdum elementum vehicula luctus, feugiat vitae arcu. +Vestibulum ut felis justo. Quisque vestibulum mauris eget ipsum luctus +consequat. Nunc tincidunt, turpis ut fermentum dapibus, +justo tortor bibendum sem, at facilisis justo odio luctus lectus. diff --git a/examples/morepages/templates/default.html b/examples/morepages/templates/default.html new file mode 100644 index 0000000..ef3e03c --- /dev/null +++ b/examples/morepages/templates/default.html @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" +"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <title>MyAweSomeCompany - $title</title> + <link rel="stylesheet" type="text/css" href="$root/css/default.css" /> + </head> + <body> + <h1>MyAweSomeCompany - $title</h1> + <div id="navigation"> + <a href="$root/index.html">Home</a> + <a href="$root/about.html">About</a> + <a href="$root/products.html">Products</a> + </div> + + <div class="column"> $section1 </div> + <div class="column"> $section2 </div> + <div class="column"> $section3 </div> + <div id="footer"> $footer </div> + </body> +</html> |