Brool brool (n.) : a low roar; a deep murmur or humming

Horrible Perl Hacks

 |  coding

Horrible, horrible hack to automatically parse the “Recently Played” section of an iTunes XML file, convert it to HTML, post it to a web site. Uses regex instead of a proper XML parser! Has everything inline instead of using Text::Template! Gross, gross, gross!

I have it set up to run every hour; it checks the timestamp of the iTunes file and does not regenerate your “Now Playing” list if the iTunes file hasn’t changed. To use in Blosxom, try the file or include plugins to bring it into your blog.

Use at your own risk.

Update (3/18). Now sort the songs by Play Date before displaying them; apparently iTunes does not always store the recently played list in play order.


Comments are moderated whenever I remember that I have a blog.

There are no comments on this article.

Add a comment