RSS generator for python
.github/ISSUE_TEMPLATE | ||
docs | ||
genrss | ||
tests | ||
.coveragerc | ||
.gitignore | ||
.travis.yml | ||
CHANGES.rst | ||
CODE_OF_CONDUCT.md | ||
LICENSE | ||
Pipfile | ||
Pipfile.lock | ||
README.md | ||
requirements-test.txt | ||
setup.py |
genrss
RSS generator for python
Installing
Install and update using pip:
pip install -U genrss
A Simple Example
from datetime import datetime
from genrss import GenRSS
feed = GenRSS(title='SmartFridge',
site_url='https://smartfridge.me',
feed_url='https://smartfridge.me/feed/rss.xml')
feed.item(title='black buns for burgers',
description='For the first time black burgers appeared ' \
'in Japan. Unusual dark color buns complemented ' \
'with black cheese and sauce. Over time, the dish ' \
'has conquered the whole world. The main secret ' \
'ingredient in popular buns is the most common... ' \
'charcoal!',
url='https://smartfridge.me/recipe/316b28-chernye-bulochki-dlya-burgerov/',
author='@smartfridge',
categories=['baking'],
pub_date=datetime.utcnow())
xml = feed.xml()
Links
Documentation: https://genrss.readthedocs.io/en/latest/