<%def name="render_item(env, conf, entry)">
    <entry>
        <title>${ entry.title | h }</title>
        <link rel="alternate" type="text/html" href="${ conf.www_root + entry.permalink }" />
        <id>tag:${ env.netloc + env.path },${ entry.date.strftime('%Y-%m-%d') }:${ entry.permalink.rstrip('/') }</id>
        <updated>${ utc(entry.date) }</updated>
        % for tag in tagify(entry.tags):
            <category term="${ tag.title }" />
        % endfor
        <author>
            <name>${ entry.author }</name>
            <uri>${ conf.www_root + '/' }</uri>
            <email>${ entry.email }</email>
        </author>
        <content type="html">${ entry.content | h }</content>
    </entry>
</%def>\
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="${ conf.lang }">
    <author>
        <name>${ conf.author }</name>
        <uri>${ conf.www_root + '/' }</uri>
        <email>${ conf.email }</email>
    </author>
    <title>${ conf.sitename | h }</title>
    <id>tag:${ env.netloc + env.path },2011-06-11:${ env.route }</id>
    <link rel="alternate" type="text/html" href="${ conf.www_root + '/' }" />
    <link rel="self" type="application/atom+xml" href="${ conf.www_root + env.route }" />
    <icon>${ conf.www_root }/favicon.ico</icon>
    <logo>${ conf.www_root }/feed-logo.png</logo>
    <updated>${ utc(env.updated) }</updated>
    <generator uri="${ env.url }" version="${ env.version }">acrylamid</generator>
    % for entry in env.entrylist:
        ${ render_item(env, conf, entry) }
    % endfor
</feed>