add rss feed
[~bandali/bndl.org] / feed_rss.m4
1 <?xml version="1.0" encoding="UTF-8" ?>
2 <rss version="2.0">
3 <channel>
4 <title>Amin Bandali's Personal Site</title>
5 <description>Notes and blog posts by Amin Bandali</description>
6 <link>https://bandali.eu.org</link>
7 <lastBuildDate>syscmd(date -uR | tr -d \\n)</lastBuildDate>
8 <pubDate>syscmd(date -uR | tr -d \\n)</pubDate>
9 <ttl>1800</ttl>
10 define(__feed_rss)dnl
11 define(`fordown',`ifelse($#,0,``$0'',`ifelse(eval($2>=$3),1,
12 `pushdef(`$1',$2)$4`'popdef(`$1')$0(`$1',decr($2),$3,`$4')')')')
13 fordown(`__i',__latest,eval(__latest-10),`
14 syscmd(sed "s/\&/\&amp;/g;s/>/\&gt;/g;s/</\&lt;/g" __i.m4 | m4 -D__feed_rss)')
15 </channel>
16 </rss>