使用Jekyll时收到“未知标签"/液体错误 [英] Getting an "Unknown tag"/Liquid error while using Jekyll
问题描述
我为Jekyll站点执行了bundle update
,然后尝试运行bundle exec jekyll serve
.我收到以下控制台消息:
I did a bundle update
for my Jekyll site, then tried to run bundle exec jekyll serve
. I got the following console message:
Liquid Exception: Liquid syntax error (line 8): Unknown tag 'when' in vendor/bundle/ruby/2.4.0/gems/liquid-4.0.0/lib/liquid/locales/en.yml
我尝试了以下操作:
-
卸载/重新安装Jekyll
uninstall/reinstall Jekyll
卸载/重新安装Gems
uninstall/reinstall Gems
卸载/重新安装Ruby
uninstall/reinstall Ruby
安装RVM
执行rm Gemfile.lock
运行bundle update
奇怪的是,当我运行rvm list
时,它显示为* ruby-2.4.1 [ x86_64 ]
.即使错误消息显示正在查看2.4.0
.然后我运行rvm list known
来找到版本4.0.0,但未列出.
Curiously, when I run rvm list
, it says * ruby-2.4.1 [ x86_64 ]
. Even though the error message says is looking at 2.4.0
. I then ran rvm list known
to find version 4.0.0 but it wasn't listed.
谢谢.
推荐答案
在您的Jekyll目录中:
In you Jekyll directory:
删除捆绑包配置和gem:
Remove bundle config and gems:
rm -r .bundle
rm -r vendor
通过捆绑安装宝石:
bundle install
运行jekyll:
bundle exec jekyll s
这篇关于使用Jekyll时收到“未知标签"/液体错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!