From 0f997ee1797a95034e7811d8d1a8e97313cab3ea Mon Sep 17 00:00:00 2001 From: Dean Attali Date: Sun, 27 Mar 2016 20:13:45 -0700 Subject: [PATCH] use post layout by default for blog posts; use same layouts as my website --- _config.yml | 1 + _layouts/base.html | 32 ++++++++++++++++++++++++++++++++ _layouts/default.html | 33 +++++---------------------------- _layouts/minimal.html | 2 +- _layouts/page.html | 10 +++++----- _layouts/post.html | 28 ++++++++++++++-------------- 6 files changed, 58 insertions(+), 48 deletions(-) create mode 100644 _layouts/base.html diff --git a/_config.yml b/_config.yml index d4100a4..77aaada 100644 --- a/_config.yml +++ b/_config.yml @@ -85,6 +85,7 @@ defaults: path: "" type: "posts" values: + layout: "post" comments: true # add comments to all blog posts - scope: diff --git a/_layouts/base.html b/_layouts/base.html new file mode 100644 index 0000000..734b4c6 --- /dev/null +++ b/_layouts/base.html @@ -0,0 +1,32 @@ +--- +common-css: + - "/css/bootstrap.min.css" + - "/css/main.css" +common-ext-css: + - "//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css" +common-googlefonts: + - "Lora:400,700,400italic,700italic" + - "Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800" +common-js: + - "/js/jquery-1.11.2.min.js" + - "/js/bootstrap.min.js" + - "/js/main.js" +--- + + + + + {% include head.html %} + + + + {% include nav.html %} + + {{ content }} + + {% include footer.html %} + + {% include footer-scripts.html %} + + + diff --git a/_layouts/default.html b/_layouts/default.html index 9944d52..919ec8e 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -1,32 +1,9 @@ --- -common-css: - - "/css/bootstrap.min.css" - - "/css/main.css" -common-ext-css: - - "//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css" -common-googlefonts: - - "Lora:400,700,400italic,700italic" - - "Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800" -common-js: - - "/js/jquery-1.11.2.min.js" - - "/js/bootstrap.min.js" - - "/js/main.js" +layout: base --- - - +
- {% include head.html %} - - - - {% include nav.html %} - - {{ content }} - - {% include footer.html %} - - {% include footer-scripts.html %} - - - +
+ {{ content }} +
\ No newline at end of file diff --git a/_layouts/minimal.html b/_layouts/minimal.html index 40f06e0..9d3f358 100644 --- a/_layouts/minimal.html +++ b/_layouts/minimal.html @@ -14,7 +14,7 @@ common-js: -
+
{{ content }}
diff --git a/_layouts/page.html b/_layouts/page.html index 5357661..38286a2 100644 --- a/_layouts/page.html +++ b/_layouts/page.html @@ -1,5 +1,5 @@ --- -layout: default +layout: base --- {% include header.html type="page" %} @@ -8,11 +8,11 @@ layout: default
{{ content }} - {% if page.comments %} + {% if page.comments %}
- {% include disqus.html %} + {% include disqus.html %}
- {% endif %} + {% endif %}
-
\ No newline at end of file + diff --git a/_layouts/post.html b/_layouts/post.html index 7f8ab67..a86e279 100644 --- a/_layouts/post.html +++ b/_layouts/post.html @@ -1,5 +1,5 @@ --- -layout: default +layout: base --- {% include header.html type="post" %} @@ -8,27 +8,27 @@ layout: default
- {{ content }} -
- + {{ content }} + + - {% if page.comments %} + {% if page.comments %}
- {% include disqus.html %} + {% include disqus.html %}
- {% endif %} + {% endif %}
- \ No newline at end of file +