Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
963 views
in Technique[技术] by (71.8m points)

ruby on rails - Bundle install could not find compatible versions for gem "bundler"

When I type bundle install I got this error. I tried to find solution but nothing solve my case. Please help me.

 Bundler could not find compatible versions for gem "bundler":
      In Gemfile:
        rails (= 4.1.8) was resolved to 4.1.8, which depends on
          bundler (< 2.0, >= 1.3.0)

      Current Bundler version:
        bundler (2.0.1)
    This Gemfile requires a different version of Bundler.
    Perhaps you need to update Bundler by running `gem install bundler`?

    Could not find gem 'bundler (< 2.0, >= 1.3.0)', which is required by gem 'rails
    (= 4.1.8)', in any of the sources.

    Bundler could not find compatible versions for gem "rails":
      In Gemfile:
        rails (= 4.1.8)

        animate-rails was resolved to 1.0.10, which depends on
          rails
See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Alternatively, you can also remove bundler 2.x completely and only use Bundler 1.x:

gem uninstall bundler -v ">= 2.0" 
gem install bundler -v "< 2.0" 

# Now you can use bundler as before
bundle install

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...