1

我刚刚用 rbenv 替换了 RVM,并清理了所有与 RVM 相关的东西。

一切都很好,除了 Jekyll 不会在 _site 内生成任何东西。

然后我尝试用 启动它--no-auto,并得到了这个异常:

/home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/psych.rb:203:in `parse': (<unknown>): found unexpected end of stream while scanning a quoted scalar at line 3 column 8 (Psych::SyntaxError)
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/psych.rb:203:in `parse_stream'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/psych.rb:151:in `parse'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/psych.rb:127:in `load'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/convertible.rb:33:in `read_yaml'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/page.rb:24:in `initialize'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/site.rb:140:in `new'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/site.rb:140:in `block in read_directories'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/site.rb:130:in `each'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/site.rb:130:in `read_directories'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/site.rb:98:in `read'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/lib/jekyll/site.rb:38:in `process'
  from /home/carlos/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/jekyll-0.11.2/bin/jekyll:250:in `<top (required)>'
  from /home/carlos/.rbenv/versions/1.9.3-p327/bin/jekyll:23:in `load'
  from /home/carlos/.rbenv/versions/1.9.3-p327/bin/jekyll:23:in `<main>'

我真的不知道它在 gems 文件夹中的“1.9.1”的位置。

ruby -v

ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-linux]

这里发生了什么?

4

1 回答 1

1

发现问题。似乎 psych 是双重加载的,一次由 gem 加载,另一次由 stdlib 加载。所以,我刚刚删除了宝石:

 gem uninstall psych 

现在它正在工作。

无论如何,在这里,获取一些相关链接:

还有一个解决方案就是将 psych gem 添加到应用程序 Gemfile。奇怪的。

于 2012-11-29T23:41:47.827 回答