Skip to content

Instantly share code, notes, and snippets.

@jdennes
Created November 8, 2010 12:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jdennes/667639 to your computer and use it in GitHub Desktop.
Save jdennes/667639 to your computer and use it in GitHub Desktop.
Automatically download the http://www.riceisnice.net playlist
# Automatically download the http://www.riceisnice.net playlist
require 'rexml/document'
`wget http://www.riceisnice.net/player/playlist.xml`
file = File.open('playlist.xml', 'r')
doc = REXML::Document.new(file.read)
files = []
doc.elements.each('playlist/item/path') do |p|
files << p.text
end
files.each do |f|
`wget #{f}`
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment