A Cool Way To Read CounterPunch
This is kind of cool - an Atom feed for Counterpunch.
If you are using Firefox, there should be an orange RSS icon in the bottom right of the browser status bar. Click on this link and select the blackcubes subscription.
Assuming my currently discombobulated server is up, this action will add a "Live Bookmark" to your browser. The "Live Bookmark" contains the titles and URLs of the last 20 or so articles that CounterPunch has published. You can use the "Open in tabs" menu option to load all the listed articles into the tabs of a single browser window, thereby reducing the effort required to read all the articles.
Alternatively, add the following URL to your favourite Atom reader: http://blackcubes.dyndns.org/atom/counterpunch.atom . However, that probably won't work so well right now because there are currently no content or summary sections in the generated feed.
The cool aspect of this is that CounterPunch doesn't actually publish an Atom feed. This Atom feed is created by subjecting their raw HTML home page to a crude sed filter, the tidy utility and an XSLT stylesheet. I'd also like to do the same for Common Dreams or any other periodical which doesn't publish an Atom feed.
The current implementation is a major hack -- the feed doesn't even properly conform to the Atom spec yet. However, it does serve as a rough prototype for a Perl program that I want to write that will be able to generate feeds from arbitrary HTML pages. The program will be extensible by plugins that either provide useful generic text extraction capabilities or contain knowledge about how specific sites are structured, so as to enable the extraction of Atom-structured text from sites that don't publish their own feeds.
I've had a quick look for other tools out there that do the same thing but haven't found anything that does quite what I want. Haloscan provides services for post-processing already extant feeds but doesn't, as far as I know, attempt to instantiate new feeds. Anyway, I am looking for a programming problem that I can use to improve my Perl programming skills.
ps: if you have tried this once and it didn't work, it was probaby a combination of strict syntax checking in FireFox 1.0 and a broken feed syntax on my part. I have now fixed the syntax errors, so it should work better now!
pps:I have created another blog -- The Crunch Manifesto -- to document the rationale for and design of a toolset to implement this idea on a larger scale. Visit that blog to read my thoughts on this and to provide feedback or design input.
pps:I have now created an atom feed for Common Dreams. Enjoy!
0 Comments:
Post a Comment
<< Home