Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
1"""
2@file
3@brief Various functions about subscriptions
4"""
6_example_subscriptions = """
7<?xml version="1.0" encoding="UTF-8"?>
8<opml version="1.0">
9<body>
11<outline text="XD Blog"
12 title="XD Blog"
13 type="rss"
14 xmlUrl="http://www.xavierdupre.fr/blog/xdbrss.xml"
15 htmlUrl="http://www.xavierdupre.fr/blog/xd_blog.html" />
17</body>
18</opml>
19"""
22def write_subscriptions_example(filename=None):
23 """
24 returns an example of a subscriptions file
26 @param filename if not None, saves the string in that file
27 @return example
28 """
29 if filename is not None:
30 with open(filename, "w", encoding="utf8") as f:
31 f.write(_example_subscriptions)
33 return _example_subscriptions