Skip to content

Instantly share code, notes, and snippets.

@jpmckinney
Created June 1, 2011 23:33
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • 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')
@solarchemist
Copy link

Fantastic! Worked like a charm.
Allowed me to add myself to my own list.

@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