Usage

Dependencies

Before you can use dilbert-rss, you will need to install two Python dependencies: BeautifulSoup and PyRSS2Gen

pip install BeautifulSoup PyRSS2Gen

BeautifulSoup and PyRss2Gen

On this topic, learning about the BeautifulSoup and PyRSS2Gen Python libraries were a benefit of using the dilbert-rss project. Both libraries can be used for a number of other useful projects. BeautifulSoup will parse an HTML page turning it into a usable Python object and PyRSS2Gen can be used to easily generate RSS feeds.

Oeey.com Dilbert Feed

Open the URL within an RSS viewer. If you don't have one handy, use Firefox to see the feed as a "Live Bookmarks" view. The content will be rendered. Most other browsers will just show the XML content.

With the above I created the following cronjob:

0 18 * * * python /usr/local/bin/dilbert.py /www/dilbert/dilbert.xml

And the matching Apache configuration, with a default DirectoryIndex pointing to the XML feed: