diff options
author | Patrick Spek <p.spek@tyil.nl> | 2021-03-05 10:22:51 +0100 |
---|---|---|
committer | Patrick Spek <p.spek@tyil.nl> | 2021-03-05 10:22:51 +0100 |
commit | 857776eb3176496d3605324945a680e08d9fc615 (patch) | |
tree | 2c5ecf00f131bee3fa721f12fbcf196eb210a8d4 /src/atom/codeofconduct.xml | |
parent | 70a2c42a5eef1dab2b7ab75e3c7f6ffc8c8c1959 (diff) |
Create a news feed per tag
Diffstat (limited to 'src/atom/codeofconduct.xml')
-rw-r--r-- | src/atom/codeofconduct.xml | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/src/atom/codeofconduct.xml b/src/atom/codeofconduct.xml new file mode 100644 index 0000000..d76b4c3 --- /dev/null +++ b/src/atom/codeofconduct.xml @@ -0,0 +1,34 @@ +--- +layout: null +--- +{% assign documents = site.documents | where: 'feed', true | where_exp: 'post', 'post.tags contains "CodeOfConduct"' | sort: 'date' | reverse %}<?xml version="1.0" encoding="UTF-8"?> +<feed xmlns="http://www.w3.org/2005/Atom"> + <id>{{ site.url }}{{ site.baseurl }}/</id> + <title>{{ site.title | xml_escape }}</title> + <subtitle>{{ site.description | strip | xml_escape }}</subtitle> + <updated>{{ site.time | date_to_xmlschema }}</updated> + <link rel="alternate" type="text/html" href="{{ site.baseurl | prepend: site.url }}" /> + <link rel="alternate" type="application/rss+xml" href="{{ "/feed.xml" | prepend: site.baseurl | prepend: site.url }}" /> + <link rel="self" type="application/atom+xml" href="{{ "/atom.xml" | prepend: site.baseurl | prepend: site.url }}" /> + <author> + <name>{{ site.author }}</name> + <email>{{ site.email }}</email> + </author> + <generator version="{{ jekyll.version }}">Jekyll</generator>{% for post in documents limit:10 %} + <entry> + <id>{{ site.url }}{{ site.baseurl }}{{ post.url }}</id> + <title>{{ post.title | xml_escape }}</title> + <author> + <name>{{ site.author }}</name> + <email>{{ site.email }}</email> + </author> + <updated>{{ post.date | date_to_xmlschema }}</updated> + <link rel="alternate" type="text/html" href="{{ post.url | prepend: site.baseurl | prepend: site.url }}" />{% if post.description %} + <summary>{{ post.description | strip | xml_escape }}</summary>{% endif %} + <content type="html" xml:base="{{ post.url | absolute_url | xml_escape }}"> + {{ post.content | strip | xml_escape }} + </content>{% for tag in post.tags %} + <category term="{{ tag | xml_escape }}" />{% endfor %}{% for cat in post.categories %} + <category term="{{ cat | xml_escape }}" />{% endfor %} + </entry>{% endfor %} +</feed> |