Hi!
Baumi said:
I have a 10.000-line AppleScript that turns iTunes DJ into an ultra-smart Radio station which learns my listening habits, automatically downloads legal free music from various places on the net, inserts songs from my back catalogue based on last.fm recommendations, plays news every hour and spices things up with podcasts, TTS weather announcements and the like. It can't run without iTunes DJ, so I won't upgrade to a version without it.
Drifting a bit off topic; just want to say that I would pay for an app that did all of that.
Really great.
Where can I get it.
Didn't look into the forums for a few days, sorry for the late response.
The problem with sharing the current version is this: Not only is the code still a bit of a mess, it's also annoying to set up, since it uses so many smart playlists, which can only be created by hand.
I did
a writeup of a much simpler version all the way back in 2005. (Extremely outdated by now, of course.)
This was the initial stage of my current script, but it's very simple compared to what it's grown into: This old version just rates music based on your listening habits, and – accordingly – plays it more or less often – that's it.
It doesn't auto-insert podcasts or news yet, nor does it have last.fm recommendations, auto-downloads of legal music, support for playing seasonal tracks at the right time, TTS weather announcements or all that jazz I added later.
I think, I never even bothered updating the documentation when launchd replaced cron. (There's a scheduled job regularly cleaning up some stuff.)
I wouldn't really recommend using this old script on your main machine: The code still contains quite a few bugs I fixed in later (private) versions – nothing dangerous, just many uncaught exceptions, very inefficient coding resulting in countless wasted CPU cycles – and, of course, the occasional hang. (I've learned quite a bit about AppleScript over the past few years ;-) )
Plus, I've seen it make iTunes' memory usage go sky-high. Not always or predictably, but it can happen. (My guess: Something about using so many smart playlists. Not sure though.)
What I'm trying to say is: Be gentle with this old code, I didn't know better at the time, and once I did, I never bothered to update that blog post. ;-)
Currently, the whole system relies too much on using iTunes as a database. My goal would be to re-write the whole thing in PHP (Perl is to messy and out-dated, and I don't feel like wrapping my brain around Python, Ruby or whatever all the kids are using these days), maintaining my own music database in SQLite and using iTunes and Spotify mainly as dumb players, so I won't have to worry so much about any internal changes there.
I'll probably be swamped with more important work until the end of June, but I hope I'll be able to whip something up over the summer – whenever I finally get around to do so, I'll definitely put it up on github or somewhere similar and make a note of it here on the boards.