mirror of
https://github.com/kremalicious/blog.git
synced 2024-11-22 01:46:51 +01:00
rss feed
This commit is contained in:
parent
1989ef1041
commit
66c5a7c269
39
_src/feed.xml
Normal file
39
_src/feed.xml
Normal file
@ -0,0 +1,39 @@
|
||||
---
|
||||
layout: none
|
||||
---
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
|
||||
<channel>
|
||||
<title>{{ site.name }}</title>
|
||||
<description>{{ site.description }}</description>
|
||||
<link>{{ site.url }}</link>
|
||||
<atom:link href="{{ site.url }}/feed.xml" rel="self" type="application/rss+xml" />
|
||||
|
||||
{% for post in site.posts limit:100 %}
|
||||
<item>
|
||||
<title>{{ post.title }}</title>
|
||||
<description>
|
||||
{% if post.image %}
|
||||
<img src="{{ site.url }}/media/{{ post.image }}" />
|
||||
{% endif %}
|
||||
|
||||
{{ post.content | xml_escape }}
|
||||
|
||||
{% if post.layout == "link" %}
|
||||
<a class="more-link" href="{{ post.linkurl }}">Go to source &#187;</a> <br />
|
||||
<a href="{{ site.url }}/{{ post.url }}" title="Permalink for this post">&#8734;</a>
|
||||
{% endif %}
|
||||
|
||||
</description>
|
||||
<pubDate>{{ post.date | date: "%a, %d %b %Y %H:%M:%S %z" }}</pubDate>
|
||||
{% if post.layout == "link" %}
|
||||
<link>{{ post.linkurl }}</link>
|
||||
{% else %}
|
||||
<link>{{ site.url }}/{{ post.url }}</link>
|
||||
{% endif %}
|
||||
<guid isPermaLink="true">{{ site.url }}/{{ post.url }}</guid>
|
||||
</item>
|
||||
{% endfor %}
|
||||
|
||||
</channel>
|
||||
</rss>
|
Loading…
Reference in New Issue
Block a user