Created
May 3, 2012 17:12
-
-
Save impronunciable/2587321 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
var Tuiter = require('tuiter') | |
, redis = require('redis'); | |
var t = new Tuiter({ | |
"consumer_key" : "your consumer key" | |
, "consumer_secret" : "your consumer secret" | |
, "access_token_key" : "your access token key" | |
, "access_token_secret" : "your access token secret" | |
}); | |
var client = redis.createClient(); | |
t.sample({}, function(stream){ | |
stream.on('data', function(data){ | |
client.lpush('twdb:tweets', JSON.stringify(data)); | |
}); | |
stream.on('error', function(){}); | |
}); | |
process.on('uncaughtException', function(){}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment