forked from tinyclub/tinylab.org
-
Notifications
You must be signed in to change notification settings - Fork 0
/
atom.xml
40 lines (40 loc) · 3.46 KB
/
atom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
---
layout: null
title : Atom Feed
---
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title>{{ site.title }}</title>
<subtitle>{{ site.tagline }}</subtitle>
<link href="{{ site.production_url }}{{ site.JB.atom_path }}" rel="self"/>
<link href="{{ site.production_url }}"/>
<updated>{{ site.time | date_to_xmlschema }}</updated>
<id>{{ site.production_url }}/</id>
<author>
<name>{{ site.data.people["admin"].name }}</name>
<email>{{ site.data.people["admin"].email }}</email>
</author>
{% capture tmpcache %}
{% capture nl0 %}
{% endcapture %}
{% endcapture %}{% assign tmpcache = nil %}
{% for post in site.posts %}
{% if post.draft and post.draft == true %}{% continue %}{% endif %}
<entry>
<title>{% capture post_title %}{{ post.title | strip_html | xml_escape | strip }}{%endcapture%}{{post_title}}</title>
<link href="{{ site.production_url }}{{ post.url }}"/>
<updated>{{ post.date | date_to_xmlschema }}</updated>
<id>{{ site.production_url }}{{ post.url }}</id>{% capture description %}{{ post.description | strip_html | replace: nl0, ' ' | replace: ' ', ' ' | replace: ' ', ' ' | replace: ' ', ' ' | strip_html | xml_escape }}{% endcapture %}{% capture summary %}{% assign tags = post.tags | join: "," %}{% assign addrs = post.addrs | join: "," %}{{ post.categories | join: "," | append: "," | append: post.keywords | append:"," | append:post.album | append:"," | append: tags | append: ',' | append: addrs | strip_html | xml_escape | downcase | split:"," | sort | uniq | join:"," }}{% endcapture %}{% if summary.size != 0 %}<summary>{{description}} {{summary | prepend:"pLACeHoldER," | replace: ",,,", "," | replace: ",,", "," | remove:'pLACeHoldER,' | strip_html }}</summary>{%endif%}
{% capture content %}{{ post.content | strip_html | replace: nl0, ' ' | replace: ' ', ' ' | replace: ' ', ' ' | replace: ' ', ' ' | strip | truncate:200 | xml_escape }}{% endcapture %}{% if content.size != 0 %}<content>{{content}}</content>{% endif %}
</entry>
{% endfor %}
{% for page in site.pages %}{% if page.url contains ".html" or page.url contains '/404/' or page.url contains "/assets/" or page.url contains ".css" or page.content contains '% assign' or page.content contains '% include' or page.content contains '% for ' or page.content contains '% if' or page.content contains '{{ site.' %}{% continue %}{% endif %} <entry>
<title>{% capture page_title %}{{ page.title | strip_html | xml_escape | strip }}{%endcapture%}{{page_title}}</title>
<link href="{{ site.production_url }}{{ page.url }}"/>
<updated>{{ site.time | date_to_xmlschema }}</updated>
<id>{{ site.production_url }}{{ page.url }}</id>
{% capture summary %}{% assign tags = page.tags | join: "," %}{% assign addrs = post.addrs | join: "," %}{{ page.categories | join: "," | append: "," | append: page.keywords | append:"," | append:post.album | append:"," | append: tags | append: ',' | append: addrs | strip_html | xml_escape | downcase | split:"," | sort | uniq | join:"," }}{% endcapture %}{% if summary.size != 0 %}<summary>{{summary | prepend:"pLACeHoldER," | replace: ",,,", "," | replace: ",,", "," | remove:'pLACeHoldER,' | strip_html }}</summary>{%endif%}
{% capture content %}{{ page.content | strip_html | replace: nl0, ' ' | replace: ' ', ' ' | replace: ' ', ' ' | replace: ' ', ' ' | strip | truncate:200 | xml_escape }}{% endcapture %}{% if content.size != 0 %}<content>{{content}}</content>{% endif %}
</entry>
{% endfor %}
</feed>