Created
February 18, 2013 00:54
-
-
Save abrcoelho/4974460 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
require 'rubygems' | |
require 'simple-rss' | |
url = File.open('ezrss.xml') # XML file from the RSS feed stored locally during development to avoid "too many requests" error. | |
rss = SimpleRSS.parse open(url) | |
TVSHOWS = %w[ | |
Alphas | |
How.I.Met.Your.Mother | |
Revolution.2012 | |
Touch | |
] | |
rss.items.each do |item| | |
TVSHOWS.each do |tvshow| | |
if item.link.include?(tvshow) | |
puts "Downloading torrent file for: #{item.title}" | |
puts "-----" | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment