Created
January 29, 2010 19:44
-
-
Save spastorino/290039 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 'twitter' | |
users = %w(wyeworks spastorino joseicosta smartinez87 nartub) | |
tweets = users.map { |user_name| Twitter::Search.new.from(user_name) }. | |
inject([]) { |tweets, search| tweets + search.fetch(5).results }. | |
sort { |t1, t2| Date.parse(t2.created_at) <=> Date.parse(t1.created_at) }[0..4] | |
tweets.each do |tweet| | |
puts tweet.created_at | |
puts tweet.from_user | |
puts tweet.profile_image_url | |
puts tweet.text | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment