Bridging NNTP and RSS #

The CS Department likes to set up newsgroups for each class to allow professor/TA/student conversations (though this custom is being supplanted by Whiteboard's discussion boards). I'm not a big Usenet person, and checking said newsgroups would involve me having to remember to go out of my way and fire up Pine. However, since (timely) announcements are often posted in newsgroups, reading them regularly is necessary. One thing that I check often (perhaps too often) is my RSS newsreader, so the obvious thing to do would be to bring newsgroups to it. Since I very rarely post, having read-only access for the most part wasn't bothersome (i.e. in those situations I can in fact fire up Pine).

The result is, a simple Perl script that uses the Net::NNTP module to generate a feed based on a newsgroups. There are two parameters (given as a query string), group to specify which group to fetch, and limit to determine how many of the most recent messages should be displayed (the NNTP server is specified as a constant within the script). This results in URLs such as:


The script handles some transformation of message bodies (newlines and conversation to HTML entities) as well as inclusion of sender/subject/date (these do have RSS equivalents, but not all aggregators display them).

N.B. I wrote this script in the spring of 2003. A search today turned up a fancier project that has appeared in the meantime. However, their approach is centralized, and wouldn't work for campus-only newsgroups like mine.

1 Comment

This is wonderful. Thanks for posting it. Saved me some time.

Post a Comment