From aa25f329b6be98d7588c723002d51e0612906949 Mon Sep 17 00:00:00 2001 From: Michael Rose Date: Fri, 8 Aug 2014 20:42:45 -0400 Subject: [PATCH] Apply author override to posts in feed --- feed.xml | 38 ++++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/feed.xml b/feed.xml index 3702bf6..ffca84b 100644 --- a/feed.xml +++ b/feed.xml @@ -1,39 +1,41 @@ --- layout: none +sitemap: false --- {{ site.title }} -Jekyll - - +Jekyll + + {{ site.time | date_to_xmlschema }} -{{ site_url }}/ +{{ site.url }}/ {{ site.owner.name }} - {{ site_url }}/ - {{ site.owner.email }} + {{ site.url }}/ + {% if site.owner.email %}{{ site.owner.email }}{% endif %} {% for post in site.posts limit:20 %} - +{% if post.author %} + {% assign author = site.data.authors[post.author] %} +{% else %} + {% assign author = site.owner %} +{% endif %} <![CDATA[{{ post.title | cdata_escape }}]]> - - {{ site_url }}{{ post.id }} + + {{ site.url }}{{ post.id }} {% if post.modified %}{{ post.modified | to_xmlschema }}T00:00:00-00:00 {{ post.date | date_to_xmlschema }} {% else %}{{ post.date | date_to_xmlschema }} {{ post.date | date_to_xmlschema }}{% endif %} - {{ site.owner.name }} - {{ site_url }} - {{ site.owner.email }} + {{ author.name }} + {{ site.url }} + {% if author.email %}{{ author.email }}{% endif %} - {% for tag in post.tags %}{% endfor %} - - {{ post.content | xml_escape }} - <p><a href="{{ site_url }}{{ post.url }}">{{ post.title }}</a> was originally published by {{ site.owner.name }} at <a href="{{ site_url }}">{{ site.title }}</a> on {{ post.date | date: "%B %d, %Y" }}.</p> - + {{ post.content | xml_escape }} + <p><a href="{{ site.url }}{{ post.url }}">{{ post.title }}</a> was originally published by {{ author.name }} at <a href="{{ site.url }}">{{ site.title }}</a> on {{ post.date | date: "%B %d, %Y" }}.</p> {% endfor %} - + \ No newline at end of file