matching the RSS build date with w3c standards

This commit is contained in:
manetta 2022-02-16 16:36:20 +01:00
parent 9944d2412c
commit 6879b73c3b
2 changed files with 1 additions and 19 deletions

View File

@ -1,18 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>{{ title }}</title>
<link>{{ log_path }}</link>
<description>Collective log writing using XMPP chat groups and LogBot.</description>
<lastBuildDate>{{ date }}</lastBuildDate>
{% for x, post in db["messages"].items() %}
<item>
<title>{{ title }}</title>
<link>{{ log_path }}#{{ x }}</link>
<description>{{ post }}</description>
<dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">LogBot</dc:creator>
<pubDate>{{ post.date }}</pubDate>
</item>
{% endfor %}
</channel>
</rss>

View File

@ -143,7 +143,7 @@ class Logbot(Bot):
), # hard-coding the URL for now
title=self.db[message.room]["title"],
db=self.db[message.room],
date=date.strftime("%A, %d. %B %Y %I:%M%p"),
date=date.strftime("%a, %d %b %Y %H:%M:%S +0100")
)
out.write(feed)
self.log.info(f"writing to: { feed_path }")