我目前正在使用:gem "omniauth", '0.3.2'
我正在尝试通过将上面的内容替换为:
来升级到omniauth 1.0.0gem 'omniauth-github', :git => 'git://github.com/intridea/omniauth-github.git' # Core, requires a OA Stratedgy gem for each provider
gem 'omniauth-facebook', :git => 'git://github.com/mkdynamic/omniauth-facebook.git' # FB OmmiAuth Stratedgy
gem 'omniauth-contrib', :git => 'git://github.com/intridea/omniauth-contrib.git' # TWITTER OmmiAuth Stratedgy
但是当我捆绑安装/更新时出现错误:
$ bundle install
Updating git://github.com/intridea/omniauth-github.git
Updating git://github.com/mkdynamic/omniauth-facebook.git
Updating git://github.com/intridea/omniauth-contrib.git
Fetching source index for http://rubygems.org/
Bundler could not find compatible versions for gem "hashie":
In snapshot (Gemfile.lock):
hashie (1.1.0)
In Gemfile:
omniauth-facebook depends on
hashie (~> 1.2)
Running `bundle update` will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.
Bundler could not find compatible versions for gem "omniauth":
In Gemfile:
omniauth-contrib depends on
omniauth (~> 1.0)
omniauth-facebook depends on
omniauth (1.0.0.rc2)
连连呢?思考? THX
答案 0 :(得分:5)
我有同样的问题。要使用omniauth-facebook gem,您需要在Gemfile中安装omniauth 1.0:
gem“omniauth”,'> = 0.3.2'
这和捆绑更新为我解决了这个问题。