can't get gemfile to allow for bundle update

前端 未结 3 1580
情歌与酒
情歌与酒 2021-01-25 13:26

I\'m a ruby/rails newbie.

Here is my gemfile:

source \'https://rubygems.org\'
ruby \'2.0.0\'
#ruby-gemset=railstutorial_rails_4_0

gem \'rails\', \'4.0.0         


        
相关标签:
3条回答
  • 2021-01-25 13:34

    Your problem is that you can only use one version of a gem at a time. the ~> will only allow for version changes on that gem.

    You need to change the version of sass-rails you're requiring to 4.0.1.

    0 讨论(0)
  • 2021-01-25 13:40

    You should update the following line in your Gemfile:

    gem 'rails', '4.0.0'
    

    to

    gem 'rails', '~> 4.0.0'
    

    and then run bundle update.

    0 讨论(0)
  • 2021-01-25 13:41

    If you put sass-rails before rails in your Gemfile, it resolves correctly.

    0 讨论(0)
提交回复
热议问题