Skip to content

Instantly share code, notes, and snippets.

@atiw003
Forked from nahi/gist:730361
Created December 6, 2010 23:34
Show Gist options
  • Save atiw003/731204 to your computer and use it in GitHub Desktop.
Save atiw003/731204 to your computer and use it in GitHub Desktop.
require 'java'
require 'twitter4j-core-2.1.8-SNAPSHOT.jar'
include_class 'twitter4j.TwitterFactory'
include_class 'twitter4j.http.AccessToken'
ck = "XXX"
cs = "XXX"
ak = "XXX"
as = "XXX"
client = TwitterFactory.new.get_oauth_authorized_instance(ck, cs, AccessToken.new(ak, as))
tweets = client.home_timeline
tweets.each do |tweet|
p tweet.text
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment