2012-03-14 62 views
2

Bundler 1.1.1似乎與rake不兼容。耙子中止! Bundler無法找到兼容版本的寶石「捆綁器」

我不知道是怎麼回事, 我試圖安裝webistrano,當我跑到下面的命令

RAILS_ENV=production rake db:migrate 

我:

耙中止!捆綁無法找到寶石 「捆綁」 兼容的版本:

在Gemfile中:

bundler (~> 1.0.10) ruby 

當前捆綁版本:

bundler (1.1.1) 

這Gemfile中需要不同版本捆綁的。 也許你需要通過運行`gem install bundler`來更新Bundler?

我真的不知道該從哪裏做些什麼,兩週前我剛剛拿起了紅寶石,並且我並不十分熟悉所有不同的寶石,以及它們應該如何工作。

其他信息

> ruby -version 
ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-linux] 

> gem list 

*** LOCAL GEMS *** 


actionmailer (3.2.2) 
actionpack (3.2.2) 
activemodel (3.2.2) 
activerecord (3.2.2) 
activeresource (3.2.2) 
activesupport (3.2.2) 
arel (3.0.2) 
bigdecimal (1.1.0) 
builder (3.0.0) 
bundler (1.1.1) 
capistrano (2.11.2) 
erubis (2.7.0) 
highline (1.6.11) 
hike (1.2.1) 
i18n (0.6.0) 
io-console (0.3) 
journey (1.0.3) 
json (1.6.5, 1.5.4) 
mail (2.4.4) 
mime-types (1.17.2) 
minitest (2.11.3, 2.5.1) 
multi_json (1.1.0) 
net-scp (1.0.4) 
net-sftp (2.0.5) 
net-ssh (2.3.0) 
net-ssh-gateway (1.1.0) 
polyglot (0.3.3) 
rack (1.4.1) 
rack-cache (1.2) 
rack-ssl (1.3.2) 
rack-test (0.6.1) 
rails (3.2.2) 
railties (3.2.2) 
rake (0.9.2.2) 
rdoc (3.12, 3.9.4) 
sprockets (2.3.1, 2.1.2) 
thor (0.14.6) 
tilt (1.3.3) 
treetop (1.4.10) 
tzinfo (0.3.32) 

謝謝。

回答

2

你可以嘗試改變:

~> 1.0.10 

少嚴格,允許新版本的一些東西,比如

>= 1.0.10 
+0

其實,在我目前的Rails項目中,我注意到我沒有在我的Gemfile中引用bundler,因此您也可以嘗試徹底刪除bundler行。 – 2012-03-15 00:25:32

+0

對不起,但〜>是什麼意思?大約到1.0.10? – confiq 2013-11-24 11:04:44

+1

@confiq我見過它叫做「悲觀版本opertator」,「twiddle waka operator」和「精子運算符」。它允許較小的更新,但不是主要的更新。所以,在這種情況下,它會更新到1.0.11,但不是1.1.0;這裏有一個很好的鏈接:http://robots.thoughtbot.com/rubys-pessimistic-operator – 2013-12-06 20:54:40

1

變化

~> 1.0.10 

~> 1.1.0 

允許您當前的Bundler gem版本(1.1.1)成功使用。

相關問題