From de59b96f5dd9d7ded6cff97ce4a11146626c884d Mon Sep 17 00:00:00 2001 From: Greg Wilson Date: Sun, 26 Jun 2016 19:14:01 -0400 Subject: [PATCH] Making pages work for workshops as well as lessons --- _layouts/base.html | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/_layouts/base.html b/_layouts/base.html index d8bbc3b..383d8b3 100644 --- a/_layouts/base.html +++ b/_layouts/base.html @@ -1,5 +1,14 @@ --- --- +{% comment %} + If previewing locally, site.root is set in _config_dev.yml. + If site.root is not set, assume we're viewing on the web. +{% endcomment %} +{% if site.root %} + {% assign root = site.root %} +{% else %} + {% assign root = site.github.url %} +{% endif %} @@ -7,10 +16,10 @@ - - - - + + + + {% if site.carpentry == "swc" %} {% endif %} @@ -29,7 +38,11 @@
{% include navbar.html %} {{ content }} + {% if site.kind == "workshop" %} + {% include workshop_footer.html %} + {% else %} {% include lesson_footer.html %} + {% endif %}
{% include javascript.html %} -- 2.30.2