这个gist可以用来订阅某个页面, 当该页面全文的md5 hash改变时, 输出的Atom feed会相应地更新. 例如订阅萝莉盟: http://rss.moe/api/source/f742582061a9b028987e?uri=http://www.loli.com/
你可以使用torabot的feed模块或者你喜欢的阅读器订阅上述链接.
这个gist可以用来订阅某个页面, 当该页面全文的md5 hash改变时, 输出的Atom feed会相应地更新. 例如订阅萝莉盟: http://rss.moe/api/source/f742582061a9b028987e?uri=http://www.loli.com/
你可以使用torabot的feed模块或者你喜欢的阅读器订阅上述链接.
<feed xml:lang='zh-CN' xmlns='http://www.w3.org/2005/Atom'> | |
<id>{{ uri }}</id> | |
<link rel='alternate' type='text/html' href='{{ uri }}'/> | |
<title>{{ uri }}</title> | |
<entry> | |
{% set hash = content.encode('ascii')|md5 %} | |
<id>{{ hash }}</id> | |
<link rel='alternate' type='text/html' href='{{ uri }}'/> | |
<title>{{ uri }}</title> | |
<content type='text'>{{ hash }}</content> | |
</entry> | |
</feed> |
{ | |
"@jinja2": { | |
"template": {"text<": "feed.xml"}, | |
"kargs": { | |
"uri": "{{ uri }}", | |
"content": { | |
"[body]": {"@request": "{{ uri }}"} | |
} | |
} | |
} | |
} |