aboutsummaryrefslogtreecommitdiff
path: root/tools/atom.py
diff options
context:
space:
mode:
authorJuan J. Martinez <jjm@usebox.net>2023-08-04 08:01:41 +0100
committerJuan J. Martinez <jjm@usebox.net>2023-08-04 08:01:41 +0100
commit39d552f1478977242b4cc09c834ccae9c3281299 (patch)
tree32e5fdd36b674febe5489f1f98fd24288cf0eb12 /tools/atom.py
parent1a2da48e1c9deb7f02ab9ccdca353ab389763d24 (diff)
downloadspacebeans-39d552f1478977242b4cc09c834ccae9c3281299.tar.gz
spacebeans-39d552f1478977242b4cc09c834ccae9c3281299.zip
Date output in RFC3339 format
Now the feed is valid.
Diffstat (limited to 'tools/atom.py')
-rwxr-xr-xtools/atom.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/atom.py b/tools/atom.py
index 7619974..aea16d5 100755
--- a/tools/atom.py
+++ b/tools/atom.py
@@ -24,7 +24,9 @@ def get_entries(changes):
m = release.match(line)
if m:
version = m.group(1)
- updated_on = datetime.fromisoformat(m.group(2)).astimezone(tz)
+ updated_on = datetime.combine(
+ datetime.fromisoformat(m.group(2)), datetime.min.time()
+ ).astimezone(tz)
body = ""
i += 1
while i < len(lines) and (lines[i] == "" or lines[i][0] != "#"):
@@ -56,9 +58,7 @@ def to_atom(post):
title="Released SpaceBeans " + post["version"],
url=base_url + "#" + post["version"],
download=base_url + "#download",
- updated_on=datetime.combine(
- post["updated_on"], datetime.min.time()
- ).isoformat(),
+ updated_on=post["updated_on"].isoformat(),
body=post["body"].rstrip() + "\n",
)