2013-03-04 62 views
34

我想對在軌道上的項目,我從GitHub同步紅寶石工作。即使成功安裝rake-10.0.3,「捆綁安裝」也會失敗。我是新來的鐵軌,不知道如何繼續這個。我GOOGLE了錯誤,並嘗試安裝不同版本的耙子的解決方案建議,但它沒有幫助。NoMethodError:私有方法'打開」呼籲寶石::包裝:分類,同時安裝耙(10.0.3)發生錯誤,並且捆紮機不能繼續

這是我正在嘗試做的...請幫助。

ruby 1.9.3p374 (2013-01-15) [i386-mingw32]

>rails s 
←[31mCould not find kaminari-0.14.1 in any of the sources←[0m 
←[33mRun `bundle install` to install missing gems.←[0m 

>bundle install 
Fetching gem metadata from https://rubygems.org/........... 
Fetching gem metadata from https://rubygems.org/.. 

NoMethodError: private method `open' called for Gem::Package:Class 
An error occurred while installing rake (10.0.3), and Bundler cannot continue. 
Make sure that `gem install rake -v '10.0.3'` succeeds before bundling. 

>gem install rake -v '10.0.3' 
Successfully installed rake-10.0.3 
Done installing documentation for rake (1 sec). 
1 gem installed 

>bundle install 
Fetching gem metadata from https://rubygems.org/........... 
Fetching gem metadata from https://rubygems.org/.. 

NoMethodError: private method `open' called for Gem::Package:Class 
An error occurred while installing rake (10.0.3), and Bundler cannot continue. 
Make sure that `gem install rake -v '10.0.3'` succeeds before bundling. 

謝謝!

+0

試試這個:你使用RVM http://stackoverflow.com/a/10741421/976775 – MrYoshiji 2013-03-04 16:27:25

+0

或ebenv? – daniloisr 2013-03-04 16:38:14

回答

89

你應該先更新的RubyGems:

gem update --system 

,然後更新捆紮機:

gem install bundler 
+0

您好,感謝您的回答,並對延遲迴復感到抱歉。 它解決後,我unistalled並重新安裝紅寶石在軌道上...... – Madhu 2013-03-09 09:47:39

+4

後人:有這個完全相同的問題,這個解決方案解決了它,不像大多數其他的東西。 – 2013-03-15 03:28:31

+1

這也解決了我的問題!謝謝! – thomax 2013-04-02 12:54:34

相關問題