forked from imathis/octopress
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added support for preserving customized source/index.html during temp…
…late updates. Moved the blog index code to a partial in source/_includes/blog_index.html
- Loading branch information
Showing
3 changed files
with
47 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<div class="blog-index"> | ||
{% assign index = true %} | ||
{% for post in paginator.posts %} | ||
{% assign content = post.content %} | ||
<article> | ||
{% include article.html %} | ||
</article> | ||
{% endfor %} | ||
<nav role="pagination"> | ||
<div> | ||
{% if paginator.next_page %} | ||
<a class="prev" href="/page{{paginator.next_page}}/">← Older</a> | ||
{% endif %} | ||
<a href="/blog/archives">Blog Archives</a> | ||
{% if paginator.previous_page and paginator.previous_page > 1 %} | ||
<a class="next" href="/page{{paginator.previous_page}}/">Newer →</a> | ||
{% elsif paginator.previous_page %} | ||
<a class="next" href="/">Newer →</a> | ||
{% endif %} | ||
</div> | ||
</nav> | ||
{% if site.disqus_short_name %} | ||
<script type="text/javascript"> | ||
var disqus_shortname = '{{ site.disqus_short_name }}'; | ||
(function () { | ||
var s = document.createElement('script'); s.async = true; | ||
s.type = 'text/javascript'; | ||
s.src = 'http://' + disqus_shortname + '.disqus.com/count.js'; | ||
(document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s); | ||
}()); | ||
</script> | ||
{% endif %} | ||
</div> | ||
<aside role=sidebar> | ||
{% if site.blog_index_asides.size %} | ||
{% include_array blog_index_asides %} | ||
{% else %} | ||
{% include_array default_asides %} | ||
{% endif %} | ||
</aside> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,5 @@ | ||
--- | ||
layout: default | ||
footer: false | ||
--- | ||
<div class="blog-index"> | ||
{% assign index = true %} | ||
{% for post in paginator.posts %} | ||
{% assign content = post.content %} | ||
<article> | ||
{% include article.html %} | ||
</article> | ||
{% endfor %} | ||
<nav role="pagination"> | ||
<div> | ||
{% if paginator.next_page %} | ||
<a class="prev" href="/page{{paginator.next_page}}/">← Older</a> | ||
{% endif %} | ||
<a href="/blog/archives">Blog Archives</a> | ||
{% if paginator.previous_page and paginator.previous_page > 1 %} | ||
<a class="next" href="/page{{paginator.previous_page}}/">Newer →</a> | ||
{% elsif paginator.previous_page %} | ||
<a class="next" href="/">Newer →</a> | ||
{% endif %} | ||
</div> | ||
</nav> | ||
{% if site.disqus_short_name %} | ||
<script type="text/javascript"> | ||
var disqus_shortname = '{{ site.disqus_short_name }}'; | ||
(function () { | ||
var s = document.createElement('script'); s.async = true; | ||
s.type = 'text/javascript'; | ||
s.src = 'http://' + disqus_shortname + '.disqus.com/count.js'; | ||
(document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s); | ||
}()); | ||
</script> | ||
{% endif %} | ||
</div> | ||
<aside role=sidebar> | ||
{% if site.blog_index_asides.size %} | ||
{% include_array blog_index_asides %} | ||
{% else %} | ||
{% include_array default_asides %} | ||
{% endif %} | ||
</aside> | ||
|
||
{% include blog_index.html %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters