Created
March 31, 2014 22:30
-
-
Save darkone23/9903869 to your computer and use it in GitHub Desktop.
moar messagez plz
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
messages = [ | |
"wow great job", | |
"en tu ano", | |
"huehuehuehue", | |
"so gud", | |
"SENDIN THAT TWEET 2 THA PYRAMID 2NITE", | |
"uh huh", | |
"how do you come up with this stuff", | |
"BOOM thought leader" | |
] | |
def get_message(): | |
index = randint(1, len(messages)) - 1 | |
return messages[index] | |
@hook.command('vw') | |
@hook.command | |
def virtualwhatever(inp): | |
'.virtualwhatever <tweet> -- become a thought leader' | |
twitter = Twitter(auth=OAuth(oauth_token, oauth_secret, CONSUMER_KEY, CONSUMER_SECRET)) | |
twitter.statuses.update(status=inp) | |
tweet = twitter.statuses.user_timeline(screen_name='virtualwhatever')[0] | |
return "%s - https://twitter.com/virtualwhatever/status/%s" % (get_message(), tweet.get('id')) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment