Replace page.root (#310)
[rnaseq-cwl-training.git] / _layouts / base.html
1 ---
2 ---
3 {% comment %}
4 When rendering websites locally, `site.github.url` doesn't get resolved
5 properly unless GitHub PAT are set up and available in the environment.
6 This leads to warnings and errors when trying to serve the site locally.
7 To work around this, we use the `jekyll.environment` variable which is set to
8 `development` when rendering the site locally, and set to `production` on
9 GitHub where `site.github.url` will be defined.
10 {% endcomment %}
11
12 {% if jekyll.environment == "development" %}
13 {% assign search_domain_url = "" %}
14 {% elsif jekyll.environment == "production" %}
15 {% assign search_domain_url = site.github.url  %}
16 {% endif %}
17
18 {% include base_path.html %}
19
20 <!doctype html>
21 <html lang="en">
22   <head>
23     <meta charset="utf-8">
24     <meta http-equiv="X-UA-Compatible" content="IE=edge">
25     <meta http-equiv="last-modified" content="{{ site.time }}">
26     <meta name="viewport" content="width=device-width, initial-scale=1">
27     <!-- meta "search-domain" used for google site search function google_search() -->
28     <meta name="search-domain" value="{{ search_domain_url }}">
29     <link rel="stylesheet" type="text/css" href="{{ relative_root_path }}/assets/css/bootstrap.css" />
30     <link rel="stylesheet" type="text/css" href="{{ relative_root_path }}/assets/css/bootstrap-theme.css" />
31     <link rel="stylesheet" type="text/css" href="{{ relative_root_path }}/assets/css/lesson.css" />
32     <link rel="stylesheet" type="text/css" href="{{ relative_root_path }}/assets/css/syntax.css" />
33
34     {% include favicons.html %}
35
36     <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
37     <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
38     <!--[if lt IE 9]>
39         <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
40         <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
41         <![endif]-->
42     <title>{{ site.title }}{% if page.title %}: {{ page.title }}{% endif %}</title>
43   </head>
44   <body>
45
46     {% include life_cycle.html %}
47
48     <div class="container">
49       {% include navbar.html %}
50 {{ content }}
51       {% if site.kind == "workshop" %}
52       {% include workshop_footer.html %}
53       {% else %}
54       {% include lesson_footer.html %}
55       {% endif %}
56     </div>
57     {% include javascript.html %}
58   </body>
59 </html>