Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
require 'rubygems'
require 'feedzirra'
# gem install feedzirra
url = "http://sunlightlabs.com/blog/feeds/tag/datacatalog/"
feed = Feedzirra::Feed.fetch_and_parse(url)
puts feed.title
puts feed.url
puts feed.feed_url
puts feed.etag
puts feed.last_modified
entries = feed.entries
entries.each do |entry|
puts "\n== #{entry.title}"
puts "url : #{entry.url}"
puts "author : #{entry.author}"
puts "summary : #{entry.summary}"
puts "context : #{entry.content}"
puts "published : #{entry.published}"
puts "categories : #{entry.categories}"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment