diff --git a/hakyll-bootstrap/Main.hs b/hakyll-bootstrap/Main.hs index 25ff32b241faa30c26d9e3ca49d82bfd00809018..1ef1ca75a1b0547e07b9d5f03b8676b412cd7742 100644 --- a/hakyll-bootstrap/Main.hs +++ b/hakyll-bootstrap/Main.hs @@ -45,9 +45,14 @@ courseCtx posts title = `mappend` constField "title" title `mappend` defaultContext -archiveCtx posts = +researchCtx posts = listField "posts" postCtx (return posts) - `mappend` constField "title" "Archives" + `mappend` constField "title" "Research projects" + `mappend` defaultContext + +bachelorCtx posts = + listField "posts" postCtx (return posts) + `mappend` constField "title" "Bachelor projects" `mappend` defaultContext indexCtx posts = @@ -101,14 +106,24 @@ posts = do >>= loadAndApplyTemplate "templates/post.html" postCtx >>= relativizeUrls -archive :: Rules () -archive = do - create ["archive.html"] $ do +research :: Rules () +research = do + create ["research_projects.html"] $ do route idRoute compile $ do - posts <- recentFirst =<< loadAll "posts/*" + posts <- recentFirst =<< loadAll "posts/research/*" + makeItem "" + >>= loadAndApplyTemplate "templates/archive.html" (researchCtx posts) + >>= relativizeUrls + +bachelor :: Rules () +bachelor = do + create ["bachelor_projects.html"] $ do + route idRoute + compile $ do + posts <- recentFirst =<< loadAll "posts/bachelor/*" makeItem "" - >>= loadAndApplyTemplate "templates/archive.html" (archiveCtx posts) + >>= loadAndApplyTemplate "templates/archive.html" (bachelorCtx posts) >>= relativizeUrls cours_conc :: Rules () @@ -136,7 +151,7 @@ cours_mti = do route $ setExtension "html" -- compile $ myPandocCompiler compile $ bibtexCompiler - >>= loadAndApplyTemplate "templates/post.html" postCtx + >>= loadAndApplyTemplate "templates/class.html" postCtx >>= relativizeUrls mti :: Rules () @@ -229,7 +244,8 @@ main = hakyllWith cfg $ do conc cours_mti mti - archive + research + bachelor index templates resizeThumbnails diff --git a/hakyll-bootstrap/img/thumbnails/palathark_logo.png b/hakyll-bootstrap/img/thumbnails/palathark_logo.png new file mode 100644 index 0000000000000000000000000000000000000000..68e8d6ce65712fd6c9962cdb12a0614ab0be33ea Binary files /dev/null and b/hakyll-bootstrap/img/thumbnails/palathark_logo.png differ diff --git a/hakyll-bootstrap/img/thumbnails/palathark_logo.svg b/hakyll-bootstrap/img/thumbnails/palathark_logo.svg new file mode 100644 index 0000000000000000000000000000000000000000..6783d7324633d95e5ab91ec27cab67848fca4fea --- /dev/null +++ b/hakyll-bootstrap/img/thumbnails/palathark_logo.svg @@ -0,0 +1,93 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="168.38773mm" + height="109.68778mm" + viewBox="0 0 168.38773 109.68778" + version="1.1" + id="svg8" + inkscape:version="1.0.1 (3bc2e813f5, 2020-09-07)" + sodipodi:docname="palathark_logo.svg" + inkscape:export-filename="/home/athas/Pictures/futhark.png" + inkscape:export-xdpi="96" + inkscape:export-ydpi="96"> + <defs + id="defs2" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:zoom="0.98994949" + inkscape:cx="61.884084" + inkscape:cy="283.39973" + inkscape:document-units="mm" + inkscape:current-layer="layer1" + showgrid="false" + inkscape:window-width="1920" + inkscape:window-height="1016" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + fit-margin-top="0" + fit-margin-left="0" + fit-margin-right="0" + fit-margin-bottom="0" + inkscape:pagecheckerboard="true" + inkscape:document-rotation="0" /> + <metadata + id="metadata5"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(-18.736665,-45.858002)"> + <g + id="g1816"> + <path + style="fill:#d40c68;stroke-width:1;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-opacity:1" + d="M 55.574356,113.31833 C 73.259169,89.293845 94.897171,83.094328 107.47147,86.992444 c 30.55329,9.881806 46.18066,17.337586 46.54319,7.526892 6.99118,0.258593 14.0565,29.165714 29.00086,33.458294 9.35408,3.39473 1.33478,5.44875 -10.02517,15.15039 -25.4335,20.73269 -150.818892,18.49702 -117.415994,-29.80969 z M 18.736665,109.74287 C 18.77709,102.51264 34.356256,102.03744 46.2531,100.9003 53.477803,89.109317 26.776689,74.554299 26.776689,74.554299 c 1.468945,-6.319892 22.978727,-2.175273 40.647748,6.773683 12.797751,-7.052309 -5.42916,-31.545451 -5.42916,-31.545451 5.054064,-6.609656 29.351226,15.232873 33.626328,22.916178 10.412335,0.415288 10.553825,-17.875835 5.775115,-25.920141 5.14529,-6.167364 22.85533,20.275791 26.73852,31.096953 7.57615,0.201456 7.5444,-4.481325 4.70365,-17.536757 4.15734,-4.880844 15.26876,21.421556 15.51322,27.833799 0.0758,8.152015 -15.57399,-1.080095 -21.47649,-2.299412 -9.96067,-4.16944 -20.73593,-8.012273 -31.67563,-5.767056 -16.436625,2.095387 -28.753136,9.428361 -41.290424,23.861125 -18.103367,25.4575 5.050961,12.09118 -35.172901,5.77565 z" + id="path4534" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cccccccccccccccccccc" /> + <path + inkscape:connector-curvature="0" + id="path63" + d="m 187.00897,46.039456 -4.7525,14.881831 -2.65593,-6.600108 -7.40843,-1.436222 z m 0,0" + style="fill:#4275a3;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.923797" /> + <path + inkscape:connector-curvature="0" + id="path63-3" + d="m 18.992658,46.039456 4.752498,14.881831 2.65593,-6.600108 7.40843,-1.436222 z m 0,0" + style="fill:#4275a3;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.923798" /> + <path + inkscape:connector-curvature="0" + id="path63-6" + d="m 18.992658,155.67254 4.7525,-14.88183 2.65593,6.60011 7.40843,1.43622 z m 0,0" + style="fill:#4275a3;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.923798" /> + <path + inkscape:connector-curvature="0" + id="path63-6-7" + d="m 187.00897,155.67254 -4.7525,-14.88183 -2.65593,6.60011 -7.40843,1.43622 z m 0,0" + style="fill:#4275a3;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.923798" /> + </g> + </g> +</svg> diff --git a/hakyll-bootstrap/index.html b/hakyll-bootstrap/index.html index 8772586c5a89dafa5c1476bdcb5fe7ddad319eec..9bf0bc60d79f235f39260e98cceadf5d39d84f71 100644 --- a/hakyll-bootstrap/index.html +++ b/hakyll-bootstrap/index.html @@ -64,41 +64,41 @@ <a class="right carousel-control" href="#myCarousel" data-slide="next"><span class="glyphicon glyphicon-chevron-right"></span></a> </div> - <!-- Marketing messaging and featurettes + <!-- Research messaging and featurettes ================================================== --> - <div class="container marketing"> + <div class="container projects"> <div class="row"> <div class="col-lg-4"> - <img class="img-square" src="img/thumbnails/boltzmann.png" alt="Generic placeholder image"> + <img class="img-square" src="img/thumbnails/boltzmann.png" alt="Palabos"> <h2>Palabos</h2> <p>The Palabos library is a general-purpose computational fluid dynamics (CFD) library, with a kernel based on the lattice Boltzmann (LB) method. It is used both as a research and an engineering tool. </p> - <p><a class="btn btn-default" href="#" role="button">View details »</a></p> + <p><a class="btn btn-default" href="https://www.palabos.org/" role="button">View details »</a></p> </div> <div class="col-lg-4"> - <img class="img-square" src="img/thumbnails/logo.png" alt="Generic placeholder image"> + <img class="img-square" src="img/thumbnails/palathark_logo.png" alt="Palathark"> + <h2>Palathark</h2> + <p>Palathark is an open source lattice Boltzmann library written in Futhark. + Its aim if to be agnostic of the underlying hardware (single core CPU, GPU, multi-threaded CPU, ...) + while remaining very efficient numerically. It is an active research topic. + </p> + <p><a class="btn btn-default" href="https://gitedu.hesge.ch/orestis.malaspin/palathark" role="button">Gitedu repo »</a></p> + </div> + <div class="col-lg-4"> + <img class="img-square" src="img/thumbnails/logo.png" alt="SimCovid"> <h2>Pandemic simulation</h2> <p>An open source agent based pandemics simulator based on the A/B street traffic simulation game. Currently under heavy development. </p> <p><a class="btn btn-default" href="https://github.com/omalaspinas/abstreet" role="button">Gthub repo »</a></p> </div> - <div class="col-lg-4"> - <img class="img-circle" data-src="holder.js/140x140" alt="Generic placeholder image"> - <h2>Heading 3</h2> - <p>Lorem ipsum dolor sit amet, consectetur adipiscing - elit. Nullam non est in neque luctus eleifend. Sed - tincidunt vestibulum facilisis. Aenean ut pulvinar massa. - </p> - <p><a class="btn btn-default" href="#" role="button">View details »</a></p> - </div> </div> - <hr class="featurette-divider"> + <!-- <hr class="featurette-divider"> <div class="row featurette"> <div class="col-md-7"> @@ -143,7 +143,7 @@ </div> </div> - <hr class="featurette-divider"> + <hr class="featurette-divider"> --> $partial("templates/footer.html")$ diff --git a/hakyll-bootstrap/templates/archive.html b/hakyll-bootstrap/templates/archive.html index f2f21cca24d073ad126cae8f7e484d018538386b..0ec1e09982b0094e2ac4fe255ff42dd3755bf71c 100644 --- a/hakyll-bootstrap/templates/archive.html +++ b/hakyll-bootstrap/templates/archive.html @@ -22,7 +22,7 @@ $partial("templates/nav.html")$ <div class="container"> - <h2>$title$</h2> + <h1>$title$</h1> <ul> $for(posts)$ <li> diff --git a/hakyll-bootstrap/templates/class.html b/hakyll-bootstrap/templates/class.html new file mode 100644 index 0000000000000000000000000000000000000000..e7c8ca6c37d3b65c4c91b0a7f4e253c184eeffd9 --- /dev/null +++ b/hakyll-bootstrap/templates/class.html @@ -0,0 +1,36 @@ +<!DOCTYPE HTML> +<html lang="en"> + <head> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="description" content=$title$> + <meta name="author" content=""> + <title>$title$</title> + <link href="/css/bootstrap.css" rel="stylesheet"> + <link href="/css/syntax.css" rel="stylesheet"> + <link href="/css/carousel.css" rel="stylesheet"> + <link href="/css/prism.css" rel="stylesheet"> + <!-- <link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'> --> + $mathjax$ + <style> + body { + font-family: 'Open Sans', sans-serif; + } + body { margin-top: 80px; } + </style> + </head> + <body> + $partial("templates/nav.html")$ + + <div class="container"> + $body$ + $partial("templates/footer.html")$ + </div> + + </div><!-- /.container --> + <script src="/js/prism.js"></script> + <script src="/js/jquery.js"></script> + <script src="/js/bootstrap.js"></script> + <script src="/js/holder.js"></script> + </body> +</html> diff --git a/hakyll-bootstrap/templates/nav.html b/hakyll-bootstrap/templates/nav.html index e43b21d6509cdb7eeeadbedb8f89c2079302fb4c..654ef324c35b2a33b4037de456efbc556420624f 100644 --- a/hakyll-bootstrap/templates/nav.html +++ b/hakyll-bootstrap/templates/nav.html @@ -15,18 +15,20 @@ <ul class="nav navbar-nav"> <li><a href="/index.html">Home</a></li> <li class="dropdown"> - <a href="#" class="dropdown-toggle" data-toggle="dropdown"> Cours <b class="caret"></b></a> + <a href="#" class="dropdown-toggle" data-toggle="dropdown"> Classes <b class="caret"></b></a> <ul class="dropdown-menu"> <li><a href="/phys_app.html">Physique appliquée</a></li> <li><a href="/math_tech_info.html">Mathématiques en technologie de l'information</a></li> <li><a href="/prog_seq.html">Programmation séquentielle en C</a></li> <li class="divider"></li> - <li class="dropdown-header">Archivés</li> + <li class="dropdown-header">Archived</li> <li><a href="#">Sciences orientation logicielle</a></li> <li><a href="#">Programmation séquentielle en Rust</a></li> <li><a href="/prog_conc.html">Programmation concurrente</a></li> </ul> - <li><a href="/archive.html">Projets</a></li> + <li><a href="/research_projects.html">Research projects</a></li> + <li><a href="/bachelor_projects.html">Bachelor projects</a></li> + <li><a href="/pages/team.html">Team</a></li> <li><a href="/pages/contact.html">Contact </a></li> </li> </ul> diff --git a/hakyll-bootstrap/templates/post.html b/hakyll-bootstrap/templates/post.html index 5331771672f3d95c9058ca7d2f2db7894163bf4e..272c559b5016b29821f6f3842246aeb7bdbf2583 100644 --- a/hakyll-bootstrap/templates/post.html +++ b/hakyll-bootstrap/templates/post.html @@ -3,14 +3,14 @@ <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <meta name="description" content=""> + <meta name="description" content=$title$> <meta name="author" content=""> <title>$title$</title> <link href="/css/bootstrap.css" rel="stylesheet"> <link href="/css/syntax.css" rel="stylesheet"> <link href="/css/carousel.css" rel="stylesheet"> <link href="/css/prism.css" rel="stylesheet"> - <link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'> + <!-- <link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'> --> $mathjax$ <style> body { @@ -23,7 +23,7 @@ $partial("templates/nav.html")$ <div class="container"> - <h2>$title$</h2> + <h1>$title$</h1> $body$ $partial("templates/footer.html")$ </div>