shadowfacts.net/site/feed.xml.ejs

38 lines
1.2 KiB
Plaintext

<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title>Shadowfacts<% if (tag) { %> (<%= tag %>)<% } %></title>
<subtitle>
<% if (tag) { %>
Only <%= tag %> posts.
<% } else { %>
Just my various ramblings.
<% } %>
</subtitle>
<% if (tag) { %>
<category term="<%= tag %>" />
<% } %>
<link rel="alternate" type="text/html" href="https://shadowfacts.net<%= permalink %>" />
<link rel="self" href="https://shadowfacts.net<%= feedPath %>" type="application/atom+xml" />
<id>https://shadowfacts.net<%= feedPath %></id>
<updated><%= new Date().toISOString() %></updated>
<author>
<name>Shadowfacts</name>
</author>
<% for (const post of posts) { %>
<entry>
<id>https://shadowfacts.net<%= post.metadata.permalink %></id>
<title><%= post.metadata.title %></title>
<updated><%= post.metadata.date.toISOString() %></updated>
<link rel="alternate" type="text/html" href="https://shadowfacts.net<%= post.metadata.permalink %>" />
<% if (post.metadata.tags) { %>
<% for (const tag of post.metadata.tags) { %>
<category term="<%= tag %>" />
<% } %>
<% } %>
<content type="html"><![CDATA[
<%- post.text %>
]]></content>
</entry>
<% } %>
</feed>