关于下载的jekyll主题启动服务器是报错问题

启动jekyll时报错

1
2
3
4
5
6
7
8
9
10
11
12
 Moon-master jekyll serve
/usr/local/lib/ruby/gems/2.4.0/gems/bundler-1.15.3/lib/bundler/runtime.rb:317:in `check_for_activated_spec!': You have already activated addressable 2.5.1, but your Gemfile requires addressable 2.4.0. Prepending `bundle exec` to your command may solve this. (Gem::LoadError)
from /usr/local/lib/ruby/gems/2.4.0/gems/bundler-1.15.3/lib/bundler/runtime.rb:32:in `block in setup'
from /usr/local/Cellar/ruby/2.4.1_1/lib/ruby/2.4.0/forwardable.rb:229:in `each'
from /usr/local/Cellar/ruby/2.4.1_1/lib/ruby/2.4.0/forwardable.rb:229:in `each'
from /usr/local/lib/ruby/gems/2.4.0/gems/bundler-1.15.3/lib/bundler/runtime.rb:27:in `map'
from /usr/local/lib/ruby/gems/2.4.0/gems/bundler-1.15.3/lib/bundler/runtime.rb:27:in `setup'
from /usr/local/lib/ruby/gems/2.4.0/gems/bundler-1.15.3/lib/bundler.rb:101:in `setup'
from /usr/local/lib/ruby/gems/2.4.0/gems/jekyll-3.5.1/lib/jekyll/plugin_manager.rb:48:in `require_from_bundler'
from /usr/local/lib/ruby/gems/2.4.0/gems/jekyll-3.5.1/exe/jekyll:9:in `<top (required)>'
from /usr/local/bin/jekyll:22:in `load'
from /usr/local/bin/jekyll:22:in `<main>'

解决

  • 安装bundle:bundle install
  • 使用启动:bundle exec jekyll serve