From 7b17dc35b66a51d5176370bd4b4d7ce01bafc1ca Mon Sep 17 00:00:00 2001 From: Maximilian Held Date: Tue, 25 Mar 2014 18:55:34 +0100 Subject: [PATCH] include link posts in post index, with external url, timestamp --- _layouts/post-index.html | 10 ++++++++-- _posts/2013-08-12-sample-link-post.md | 6 +++++- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/_layouts/post-index.html b/_layouts/post-index.html index dc70107e..83b94ddf 100644 --- a/_layouts/post-index.html +++ b/_layouts/post-index.html @@ -47,8 +47,14 @@ {% endif %} {% endunless %}
-

{{ post.title }}

-

{% if post.description %}{{ post.description }}{% else %}{{ post.content | strip_html | strip_newlines | truncate: 120 }}{% endif %}

+ {% if post.link %} +

{{ post.title }}

+

{{ post.date | date: "%B %d %H:%M %Z"}}

+

{{ post.content }}

+ {% else %} +

{{ post.title }}

+

{% if post.description %}{{ post.description }}{% else %}{{ post.content | strip_html | strip_newlines | truncate: 120 }}{% endif %}

+ {% endif %}
{% endfor %} diff --git a/_posts/2013-08-12-sample-link-post.md b/_posts/2013-08-12-sample-link-post.md index b9db0eea..f7711aab 100644 --- a/_posts/2013-08-12-sample-link-post.md +++ b/_posts/2013-08-12-sample-link-post.md @@ -7,4 +7,8 @@ link: http://mademistakes.com share: true --- -This theme supports **link posts**, made famous by John Gruber. To use, just add `link: http://url-you-want-linked` to the post's YAML front matter and you're done. \ No newline at end of file +This theme supports **link posts**, made famous by John Gruber. To use, just add `link: http://url-you-want-linked` to the post's YAML front matter and you're done. + +> And this is how a quote looks. + +Some [link](http://www.mademistakes.com) can also be shown. \ No newline at end of file