Error log
Liquid Exception: Liquid syntax error (line 6): Unknown tag 'include_cached' in /_layouts/post.html
I am currently making a blog by forking this project at https://github.com/hydecorp/hydejack.
I've tried several methods for 2 days, but it doesn't work. Locally it's fine, but when I build I get an error.
this is my project
https://github.com/JangHwanPark/JangHwanPark.github.io
I tried changing config.yml and layout to md file. I also tried deleting the repository, but it didn't work.
CodePudding user response:
When you build the way you do, the "classic" way (as opposed to using an action), GitHub uses a fixed configuration and a list of whitelisted plugins (visible here). It really only includes the github-pages
gem, which includes all other dependencies. Your Gemfile is ignored for the build; among other things, this means the build uses Jekyll v3.9.2, and not v4.1 as in your Gemfile.
There are two approaches:
Stick with the "classic" experience. I recommend you make your local environment match that; the Gemfile simplifies to
source "https://rubygems.org" gem "github-pages", "~> 227", group: :jekyll_plugins
Don't forget to run
bundle install
after you've updated the Gemfile so the lockfile gets updated, too.You'll have to update
_config.yml
to include your theme via theremote-theme
plugin, and add theinclude-cache
plugin to theplugins
list.This closely matches what the docs for your theme also recommend.
Switch to a custom GitHub Actions flow to deploy your page. There is a starter workflow for Jekyll; using that should get you most of the way there. You might still have to specify
remote_theme
in the config instead oftheme
, unless you copy the entire theme into your repo.Doing this lets you use any gems you want, and any Jekyll version you want.