This Ruby script creates or overrides an iTunes playlist containing your loved last.fm tracks.
ruby loved2itunes.rb -h
ruby loved2itunes.rb -u kain82 -n MyLovedTracks -e # will import loved tracks into MyLovedTracks playlist and excludes videos.
ruby loved2itunes.rb -u kain82 # will import loved tracks into Loved playlist and includes videos.
ruby loved2itunes.rb -u kain82 -e -v # run verbosely, exclude videos
This script is ideal to keep in sync with your last.fm loved tracks. For example this will run hourly:
01 * * * * /path/to/loved2itunes.rb -u username
You can also use another last.fm username and try to import the loved tracks of another person/account if you have the required files in your library.
Tested on Snow Leopard with iTunes:
- 8.2.6
- 9.0
Two rubygems are required in order to run loved2itunes, nokogiri and rb-appscript.
Open a terminal and issue those commands:
sudo gem install nokogiri --no-rdoc --no-ri
sudo gem install rb-appscript --no-rdoc --no-ri
Run the script as described above.
This is an experimental feature.
Tested on Windows XP SP3 with iTunes:
- 8.2.6
Download and install Ruby.
After the installation completes, start a command prompt, Start -> Run -> write cmd and press return.
Issue those commands to update rubygems:
gem update --system
Then install the required gem:
gem install nokogiri --no-rdoc --no-ri
Run the script as described above.