From d635e5faf9878ff125b05c09f952c800547c9d5e Mon Sep 17 00:00:00 2001 From: Set Hallstrom Date: Tue, 17 Nov 2020 00:22:50 +0100 Subject: [PATCH] add atom feed and make RSS feed work with images --- atom.xml | 25 +++++++++++++++++++------ _rss.xml => rss.xml | 19 ++++++++++--------- 2 files changed, 29 insertions(+), 15 deletions(-) rename _rss.xml => rss.xml (54%) diff --git a/atom.xml b/atom.xml index 487bada..393ab02 100644 --- a/atom.xml +++ b/atom.xml @@ -4,22 +4,35 @@ layout: nil {{ site.title }} - + {{ site.description | xml_escape }} + {{ site.time | date_to_xmlschema }} - {{ site.url }}/feed.xml + {{ site.url }}/atom.xml {{ site.publisher.name }} + {{ site.publisher.mail }} Copyleft {{ site.time | date: '%Y' }} {{ site.publisher.name }} + {{ site.url }}{{ site.icon }} + {{ site.url }}{{ site.icon }} - {% for post in site.posts limit:20 %} + {% for post in site.posts limit:10 %} {{ post.title }} - {{ post.date | date_to_xmlschema }} - home_url{{ post.id }} - {{ post.content | xml_escape }} + {{ post.date | date_to_xmlschema }} + {{ post.last_modified_at | date_to_xmlschema }} + {{ site.url }}{{ post.url }} + {{ post.content | strip_html | truncate: 220 | xml_escape }} + {{ post.description }} + +{% assign author_id = post.author | prepend: "/authors/" | append: "/" %} +{% assign author = site.authors | where: "url", author_id | first %} + {{ author.name }} + {{ author.email }} + {{ author.url_staff }} + {% endfor %} \ No newline at end of file diff --git a/_rss.xml b/rss.xml similarity index 54% rename from _rss.xml rename to rss.xml index 84a6172..7b1516e 100644 --- a/_rss.xml +++ b/rss.xml @@ -2,18 +2,16 @@ layout: nil title : The Basspistol RSS Feed --- - - - + + + {{ site.title | xml_escape }} - + {{ site.url }} {{ site.description | xml_escape }} {{ site.time | date_to_rfc822 }} en-US - hourly - 1 https://jekyllrb.com/ {{ site.url }}/siteicon.png @@ -31,10 +29,13 @@ title : The Basspistol RSS Feed {{ site.url }}{{ post.url }} {{ post.description | truncate: 200 | xml_escape }} Hi-Lights - {{ site.publisher.mail | xml_escape }} ({{ site.publisher.name }}) + {% assign author_id = post.author | prepend: "/authors/" | append: "/" %} + {% assign author = site.authors | where: "url", author_id | first %} + {{ author.name }} + {{ author.email }} ({{ author.name }}) {{ post.date | date_to_rfc822 }} - - {{ post.title | xml_escape }} + + {{ post.title | xml_escape }} {% endfor %}