Commit f96b495b authored by Antoine Catton's avatar Antoine Catton

Prettier atom feed.

parent b14261dd
...@@ -48,7 +48,7 @@ def get_feed(feed): ...@@ -48,7 +48,7 @@ def get_feed(feed):
entries.append(Entry(title=title, entries.append(Entry(title=title,
guid=guid, guid=guid,
updated=datetime.fromtimestamp(timestamp), updated=datetime.fromtimestamp(timestamp),
content=Content(content), content=Content(content, content_type='html'),
)) ))
feed = Feed(title=feed_title, feed = Feed(title=feed_title,
updated=datetime.fromtimestamp(feed_updated), updated=datetime.fromtimestamp(feed_updated),
......
...@@ -41,12 +41,15 @@ def main(): ...@@ -41,12 +41,15 @@ def main():
command.stdin.close() command.stdin.close()
if command.wait() != 0: if command.wait() != 0:
content = "Failed with returncode %d and stderr %r" % ( content = ("<p>Failed with returncode <em>%d</em>.</p>"
"<p>Standard error output is :</p><pre>%s</pre>") % (
command.poll(), command.poll(),
command.stderr.read(), command.stderr.read().replace('&', '&amp;')\
.replace('<', '&lt;')\
.replace('>', '&gt;'),
) )
else: else:
content = "Everything went well." content = "<p>Everything went well.</p>"
with open(args.logfile[0], 'a') as file_: with open(args.logfile[0], 'a') as file_:
cvsfile = csv.writer(file_) cvsfile = csv.writer(file_)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment