From 2051cd66c9c02777e2eff1789ce2d1f76dd2e7e9 Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Wed, 30 Dec 2015 17:30:38 -0800 Subject: Get rid of 'evernote-oauth' and install 'omniauth' Removing the 'evernote-oauth' gem because I couldn't figure out how to get it to work. Decided to go with OmniAuth to handle OAuth because I had a good experience with it in the past and figured it would be simpler to set up. Also installing the 'omniauth-evernote' provider to enable authentication with Evernote. Comment out the route I had created to `auth/evernote#index` for 'evernote-oauth'. --- Gemfile | 5 ++++- Gemfile.lock | 17 +++++++++++++---- config/routes.rb | 2 +- 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/Gemfile b/Gemfile index 33b3726..953364f 100644 --- a/Gemfile +++ b/Gemfile @@ -32,7 +32,10 @@ gem 'sdoc', '~> 0.4.0', group: :doc # Use Capistrano for deployment # gem 'capistrano-rails', group: :development -gem 'evernote_oauth' +# gem 'evernote_oauth' + +gem 'omniauth' +gem 'omniauth-evernote' group :development, :test do # Call 'byebug' anywhere in the code to stop execution and get a debugger console diff --git a/Gemfile.lock b/Gemfile.lock index c90dcae..c698d48 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -52,12 +52,10 @@ GEM debug_inspector (0.0.2) erubis (2.7.0) evernote-thrift (1.25.2) - evernote_oauth (0.2.3) - evernote-thrift - oauth (>= 0.4.1) execjs (2.6.0) globalid (0.3.6) activesupport (>= 4.1.0) + hashie (3.4.3) i18n (0.7.0) jbuilder (2.4.0) activesupport (>= 3.0.0, < 5.1) @@ -78,6 +76,16 @@ GEM nokogiri (1.6.7.1) mini_portile2 (~> 2.0.0.rc2) oauth (0.4.7) + omniauth (1.3.1) + hashie (>= 1.2, < 4) + rack (>= 1.0, < 3) + omniauth-evernote (1.2.1) + evernote-thrift + multi_json (~> 1.0) + omniauth-oauth (~> 1.0) + omniauth-oauth (1.1.0) + oauth + omniauth (~> 1.0) rack (1.6.4) rack-test (0.6.3) rack (>= 1.0) @@ -149,9 +157,10 @@ PLATFORMS DEPENDENCIES byebug coffee-rails (~> 4.1.0) - evernote_oauth jbuilder (~> 2.0) jquery-rails + omniauth + omniauth-evernote rails (= 4.2.5) sass-rails (~> 5.0) sdoc (~> 0.4.0) diff --git a/config/routes.rb b/config/routes.rb index cb4962f..a729a7f 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -1,7 +1,7 @@ Rails.application.routes.draw do root 'home#index' - get '/auth/evernote' => 'auth/evernote#index' + # get '/auth/evernote' => 'auth/evernote#index' # The priority is based upon order of creation: first created -> highest priority. # See how all your routes lay out with "rake routes". -- cgit v1.2.3