Jekyll: Liquid Tags used in Sub-directories

286 views Asked by At

I am trying include a certain markdown file that is in the root directory into another file that is in a sub-directory.

I tried many different syntaxes:

{% include_relative ../root/file %}
{% include_relative /../root/file %}
{% include_relative ./../root/file %}
{% include_relative /./../root/file %}
(and others)

Is there any way to go back to parent directories in Jekyll using Liquid Tags?

1

There are 1 answers

0
David Jacquel On

From jekyll documentation.

For example, if _posts/2014-09-03-my-file.markdown uses the include_relative tag, the included file must be within the _posts directory, or one of its subdirectories. You cannot include files in other locations.