Monday, February 05, 2007

I'm an avid listener of podcasts, and use the excellent peapod.py podcatching software. It runs from the commandline and is absolutely gorgeous. It uses an XML file for configuration, and to add files to it, I use Emacs and add a new:

<feed>
<url></url>
<title></title>
</feed>


to the end of the file. That's really sweet, and slightly hardcore.

To run it, I just have a crontab entry that runs at times when I'm usually not on the computer:

0 5,13,18 * * * /usr/sness/peapod/peapod.py >& /dev/null

So, when I wake up, come back from the gym, and after supper, there are podcasts all ready for me! So sweet.

I was reading the logfile for it recently, and was wondering what the following meant:

etag unchanged, not fetching: http://geekbrieftv.podshow.com/feed.xml

So, etags are actually really cool, here's RFC 2616 which describes it in detail. And a blog post about it.

Basically, etags are returned by the server in the content header, and tell you if the content of the page has changed or not. If it hasn't, you can add the If-None-Match header to your request, so that you don't have to download the URL if it hasn't changed. Sweet.