Skip to content

Instantly share code, notes, and snippets.

@jpmckinney
Created June 1, 2011 23:33
Show Gist options
  • Save jpmckinney/1003604 to your computer and use it in GitHub Desktop.
Save jpmckinney/1003604 to your computer and use it in GitHub Desktop.
Add yourself to your Twitter list
# blog post: http://blog.slashpoundbang.com/post/6087617126/how-to-add-yourself-to-your-own-twitter-list
#!/usr/bin/env ruby
require 'twitter'
# Replace the four strings below with your own values.
Twitter.configure do |config|
config.consumer_key = 'CONSUMER_KEY'
config.consumer_secret = 'CONSUMER_SECRET'
config.oauth_token = 'OAUTH_TOKEN'
config.oauth_token_secret = 'OAUTH_TOKEN_SECRET'
end
# Replace the two strings below with the list name and your user name.
Twitter.list_add_member('LIST_NAME', 'YOUR_TWITTER_USER_NAME')
@TMKCodes
Copy link

You should remember to require 'rubygems' before requiring twitter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment