Skip to content

Instantly share code, notes, and snippets.

@ewheeler
Created May 13, 2011 18:02
Show Gist options
  • Save ewheeler/971004 to your computer and use it in GitHub Desktop.
Save ewheeler/971004 to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
# vim: ai ts=4 sts=4 et sw=4 coding=utf-8
import tweetstream
import datetime
import getpass
import sys
words = ["unicef", "innovation", "bunnies"]
def go():
user = raw_input("Enter your twitter username and press enter:")
password = getpass.getpass("Enter your twitter password and press enter:")
with tweetstream.TrackStream(user, password, words) as stream:
for tweet in stream:
sys.stdout.write('.')
sys.stdout.flush()
print tweet
import pdb;pdb.set_trace()
if __name__ == "__main__":
go()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment