当我从我的应用程序根目录执行bundle install
时,我收到以下错误
Unfortunately, a fatal error has occurred. Please see the Bundler troubleshooting documentation at http://bit.ly/bundler-issues. Thanks!
/Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/fileutils.rb:245:in `mkdir': Permission denied - /home/kumolus (Errno::EACCES)
from /Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/fileutils.rb:245:in `fu_mkdir'
from /Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/fileutils.rb:219:in `block (2 levels) in mkdir_p'
from /Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/fileutils.rb:217:in `reverse_each'
from /Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/fileutils.rb:217:in `block in mkdir_p'
from /Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/fileutils.rb:203:in `each'
from /Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/fileutils.rb:203:in `mkdir_p'
from /Users/cuelogic/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/pathname.rb:556:in `mkpath'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/installer.rb:52:in `run'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/installer.rb:14:in `install'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/cli.rb:247:in `install'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/vendor/thor/task.rb:27:in `run'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/vendor/thor/invocation.rb:120:in `invoke_task'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/vendor/thor.rb:344:in `dispatch'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/vendor/thor/base.rb:434:in `start'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/bin/bundle:20:in `block in <top (required)>'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/lib/bundler/friendly_errors.rb:3:in `with_friendly_errors'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/gems/bundler-1.3.5/bin/bundle:20:in `<top (required)>'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/bin/bundle:23:in `load'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247@global/bin/bundle:23:in `<main>'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247/bin/ruby_executable_hooks:15:in `eval'
from /Users/cuelogic/.rvm/gems/ruby-2.0.0-p247/bin/ruby_executable_hooks:15:in `<main>'
我试过在网上找到这个,但我找不到任何解决方案。
我正在使用
ruby 2.0.0p247 (2013-06-27 revision 41674) [x86_64-darwin12.5.0]
rvm 1.22.14 (stable) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/]
答案 0 :(得分:0)
我从here开始执行以下步骤,之后错误消失了
# remove user-specific gems and git repos
rm -rf ~/.bundle/ ~/.gem/bundler/ ~/.gems/cache/bundler/
# remove system-wide git repos and git checkouts
rm -rf $GEM_HOME/bundler/ $GEM_HOME/cache/bundler/
# remove project-specific settings
rm -rf .bundle/
# remove project-specific cached gems and repos
rm -rf vendor/cache/
# remove the saved resolve of the Gemfile
rm -rf Gemfile.lock
# uninstall the rubygems-bundler and open_gem gems
rvm gemset use global # if using rvm
gem uninstall rubygems-bundler open_gem
# try to install one more time
bundle install