Add feed and link to feed in header. Props @benbalter

This commit is contained in:
Parker Moore 2013-07-06 18:05:27 +02:00
parent 6950809900
commit b6c86579f3
2 changed files with 37 additions and 0 deletions

View File

@ -4,6 +4,7 @@
<meta charset="UTF-8"> <meta charset="UTF-8">
<title>{{ page.title }}</title> <title>{{ page.title }}</title>
<meta name="viewport" content="width=device-width,initial-scale=1"> <meta name="viewport" content="width=device-width,initial-scale=1">
<link rel="alternate" type="application/rss+xml" title="Jekyll • Simple, blog-aware, static sites - Feed" href="/feed.xml" />
<link href='http://fonts.googleapis.com/css?family=Lato:100,300,400,700,900,100italic,300italic,400italic,700italic,900italic' rel='stylesheet' type='text/css'> <link href='http://fonts.googleapis.com/css?family=Lato:100,300,400,700,900,100italic,300italic,400italic,700italic,900italic' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Arizonia' rel='stylesheet' type='text/css'> <link href='http://fonts.googleapis.com/css?family=Arizonia' rel='stylesheet' type='text/css'>
<link rel="stylesheet" href="{{ site.url }}/css/normalize.css" /> <link rel="stylesheet" href="{{ site.url }}/css/normalize.css" />

36
site/feed.xml Normal file
View File

@ -0,0 +1,36 @@
---
layout: none
permalink: /feed.xml
---
<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:wfw="http://wellformedweb.org/CommentAPI/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
>
<channel>
<title xml:lang="en">Jekyll • Simple, blog-aware, static sites</title>
<atom:link type="application/atom+xml" href="http://jekyllrb.com/feed/" rel="self"/>
<link>http://jekyllrb.com</link>
<pubDate>{{ site.time | date: "%a, %d %b %Y %H:%M:%S %z" }}</pubDate>
<lastBuildDate>{{ site.time | date: "%a, %d %b %Y %H:%M:%S %z" }}</lastBuildDate>
<language>en-US</language>
<description>Transform your plain text into static websites and blogs.</description>
{% for post in site.posts %}
<item>
<title>{{ post.title }}</title>
<link>http://jekyllrb.com{{ post.url }}</link>
<pubDate>{{ post.date | date: "%a, %d %b %Y %H:%M:%S %z" }}</pubDate>
<dc:creator>{{ post.author }}</dc:creator>
{% for tag in post.tags %}<category>{{ tag | xml_escape }}</category>
{% endfor %}{% for cat in post.categories %}<category>{{ cat | xml_escape }}</category>
{% endfor %}<guid isPermaLink="false">{{ post.id }}</guid>
<description><![CDATA[ {{ post.content }} ]]></description>
</item>
{% endfor %}
</channel>
</rss>