Created
January 7, 2012 12:44
-
-
Save tbaba/1574666 to your computer and use it in GitHub Desktop.
Post to Twitter with OmniAuth
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
gem 'omniauth' | |
gem 'omniauth-twitter' |
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
Rails.application.config.middleware.use OmniAuth::Builder do | |
provider :twitter, YOUR_CONSUMER_KEY, YOUR_CONSUMER_SECRET | |
end |
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
Hoge::Application.routes.draw do | |
match '/auth/:provider/callback' => 'sessions#callback' | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment