2016-06-13 57 views
0

我试图推动我的项目heroku,我得到这个错误。无法降级heroku

Your Ruby version is 2.3.0, but your Gemfile specified 2.3.0 
remote:  Bundler Output: Warning: the running version of Bundler is older than the version that created the lockfile. We suggest you upgrade to the latest version of Bundler by running `gem install bundler`. 

我也使用rvm。

看起来好像heroku捆绑器使用1.11.2所以我试图从1.12.5降级我的版本。

我没宝石卸载捆绑那么创业板安装捆绑--version“1.11.2”

然而,当我做捆绑-v,它仍然显示1.12.5

但是当我做宝石卸载捆绑,它显示 已成功卸载bundler-1.11.2

我仍然无法推送,并且出现该错误。请帮忙。

回答

1

请按照下列步骤操作;

http://rubygems.rubyforge.org/rubygems-update/UPGRADING_rdoc.html

还有一件事,我认为你的捆绑安装在RVM默认宝石即系统宝石。

请尝试检查此内容;

在终端做rvm list,这会给你这样的输出;

rvm rubies 

    ruby-2.0.0-p643 [ x86_64 ] 
=* ruby-2.1.4 [ x86_64 ] 
    ruby-2.2.1 [ x86_64 ] 
    ruby-2.2.4 [ x86_64 ] 

现在做rvm gemset list;这会给你这样的结果;

(default) 
    global 
    some-gemset 

入住这宝石在你的系统中使用它,就可以认定为=> global当你做rvm gemset list。当你确定在宝石您目前在现在

,做这样的事情rvm use [email protected]

即可;

gem uninstall bundler 

或者在一个步骤中你可以这样做;

rvm @global do gem uninstall bundler 

然后像这样安装你想要的捆绑器版本;

gem install bundler --version '1.11.2' 

希望这可以帮助你。