Friday, January 9, 2009

Quick'n'Dirty: Create your own local podcast in iTunes

I wrote a Quick'n'Dirty script tonight so that I could import a bunch of assorted mp3 audio files on to my iPod in the form of a Podcast.

Why?

Imagine you have a bunch of lectures by a guy at Google recorded at a university. They are available as randomly assorted mp3 audio files. Rather than suffer through trying to listen to them one by one on your iPod, you use this script to create an XML file that fakes a podcast. By creating my own fake podcast in iTunes, I can take a series of mp3 audio files, set them in a specific order, listen to each one, and have the iPod automatically discard the file when I am done.

So here's what you do under Mac OS X 10.5, with this fugly script.. dir2pod.pl

Warning: This script comes with no warranties or licenses. :)

  1. Go to Apple -> System Preferences -> Sharing

  2. Enable Web Sharing

  3. In your Sites directory, create Podcasts

  4. Make sure Podcasts has read-only permissions for everyone (use APPL-I if you need to change the permissions)

  5. Move dir2pod.pl into Podcasts, make sure it is executable (APPL-I again)

  6. Copy your directory of mp3 audio files into Podcasts as a subdirectory (so for example, you'd have Podcasts/Myshow if your mp3 files were in a directory named Myshow)

  7. Run the following command from The Shell

    $ cd ~/Sites/Podcasts && ./dir2pod.pl Myshow/ > Myshow.xml


  8. In iTunes, go to Advanced -> Subscribe to Podcast... And enter;

    http://localhost/~YOURUSERNAME/Podcasts/Myshow.xml


  9. If everything went well, iTunes will detect the podcast and will try and download the last file. Click on "Get All" to download all the files in that directory.



If you want to try this script out, but it's not working for you, pass me a comment and I'll see if I can tell you where it's going wrong.

No comments:

Post a Comment