Skip to content

Instantly share code, notes, and snippets.

@frazras
Created January 13, 2014 02:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save frazras/8393696 to your computer and use it in GitHub Desktop.
Save frazras/8393696 to your computer and use it in GitHub Desktop.
note to self: This code will get all tweets authored by me that I favorited and select 15 random tweets then send them to the buffer API to be queued for tweeting
fav = api.GetFavorites(count=200)
size = len( [elem for elem in fav if elem.user.screen_name=='frazras'])
pp( [[profile.updates.new(unicodedata.normalize('NFKD', (elem.text)).encode('ascii','ignore')) for elem in fav if elem.user.screen_name=='frazras'][i] for i in random.sample(xrange(size), 15)])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment