-
Notifications
You must be signed in to change notification settings - Fork 380
/
feed.xml
35 lines (33 loc) · 1.33 KB
/
feed.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
---
layout: null
---
<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title>{{ site.title | xml_escape }}</title>
<link>{{ site.url }}</link>
<description>{{ site.description | xml_escape }}</description>
<lastBuildDate>{{ site.time | date_to_rfc822 }}</lastBuildDate>
{% assign posts_limit = site.feed.posts_limit | default: 10 %}
{% for post in site.posts limit: posts_limit %}
<item>
<title>{{ post.title | xml_escape }}</title>
<link>
{{ post.url | prepend: site.url }}
</link>
<description>
{{ post.content | xml_escape }}
</description>
<pubDate>{{ post.date | date_to_rfc822 }}</pubDate>
<guid>
{{ post.url | prepend: site.url }}
</guid>
{% assign post_author = post.author | default: post.authors[0] | default: site.author %}
{% assign post_author = site.data.authors[post_author] | default: post_author %}
{% if post_author %}
<author>{{ post_author.name | default: "" | xml_escape }}{% if post_author.twitter %} (https://twitter.com/{{ post_author.twitter | xml_escape }}){% endif %}</author>
{% endif %}
</item>
{% endfor %}
</channel>
</rss>