]> git.sur5r.net Git - i3/i3.github.io/blob - _templates/rss.mako
downloads: mark a few more versions as old
[i3/i3.github.io] / _templates / rss.mako
1 <?xml version="1.0" encoding="UTF-8"?><% from datetime import datetime %>
2 <rss version="2.0"
3      xmlns:content="http://purl.org/rss/1.0/modules/content/"
4      xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
5      xmlns:atom="http://www.w3.org/2005/Atom"
6      xmlns:dc="http://purl.org/dc/elements/1.1/"
7      xmlns:wfw="http://wellformedweb.org/CommentAPI/"
8      >
9   <channel>
10     <title>${bf.config.blog.name}</title>
11     <link>${bf.config.blog.url}</link>
12     <description>${bf.config.blog.description}</description>
13     <pubDate>${datetime.utcnow().strftime("%a, %d %b %Y %H:%M:%S GMT")}</pubDate>
14     <generator>Blogofile</generator>
15     <sy:updatePeriod>hourly</sy:updatePeriod>
16     <sy:updateFrequency>1</sy:updateFrequency>
17 % for post in posts[:10]:
18     <item>
19       <title>${post.title}</title>
20       <link>${post.permalink}</link>
21       <pubDate>${post.date.strftime("%a, %d %b %Y %H:%M:%S %Z")}</pubDate>
22 % for category in post.categories:
23       <category><![CDATA[${category}]]></category>
24 % endfor
25 % if post.guid:
26       <guid>${post.guid}</guid>
27 % else:
28       <guid isPermaLink="true">${post.permalink}</guid>
29 % endif
30       <description>${post.title}</description>
31       <content:encoded><![CDATA[${post.content}]]></content:encoded>
32     </item>
33 % endfor
34   </channel>
35 </rss>