我使用sudo bundle install
,这可能是问题的原因?
现在我有:
gem -v
2.6.14ruby -v
ruby 2.3.5p376 (2017-09-14 revision 59905) [x86_64-darwin15]jekyll -v
jekyll 3.6.2bundle -v
Bundler版本1.16.0.pre.3当我试图运行bundle exec jekyll serve
或只是jekyll serve
时,我得到以下错误
/Users/myusername/.rvm/rubies/ruby-2.3.5/lib/ruby/site_ruby/2.3.0/rubygems.rb:271:in `find_spec_for_exe': can't find gem bundler (>= 0.a) (Gem::GemNotFoundException)
from /Users/myusername/.rvm/rubies/ruby-2.3.5/lib/ruby/site_ruby/2.3.0/rubygems.rb:299:in `activate_bin_path'
from /Users/myusername/.rvm/gems/ruby-2.3.5/bin/bundle:23:in `<main>'
from /Users/myusername/.rvm/gems/ruby-2.3.5/bin/ruby_executable_hooks:15:in `eval'
from /Users/myusername/.rvm/gems/ruby-2.3.5/bin/ruby_executable_hooks:15:in `<MacBooMacBook-MacBook-MacBook-Pro-MacBook-PrMacBook-MacBooMacBMaMacBMaMaMaMaMaMaMaMaMacBMaMaMaMacBMa
另外,当访问我的博客cd my_path
所在的文件夹时,我得到以下消息:
VM使用你的Gemfile来选择Ruby,这一切都很好- Heroku也这样做, 你可以通过'rvm rvmrc warning ignore /Library/WebServer/Documents/blog/Gemfile'忽略这些警告。 要忽略所有文件的警告,请执行'rvm rvmrc warning ignore allGemfiles'命令。 未知ruby解释器版本(不知道如何处理):RUBY_VERSION.
我不知道该怎么解决。我只是想创建我的静态博客,老实说,我不知道Ruby, Gem或Bundle:)所以我很感激一些见解!