Yaml 杰基尔的帖子没有在网站上列出。如何修复?

Yaml 杰基尔的帖子没有在网站上列出。如何修复?,yaml,jekyll,liquid,Yaml,Jekyll,Liquid,我第一次用Jekyll建立了一个网站,我一直在遵循Jekyll文档中列出的逐步教程。我已经按照中所述创建了帖子、布局和帖子列表(blog.html),但是当我在命令行中运行jekyll-serve时,我的帖子不会在blog.html中列出。这可能是什么原因 这是我的\u config.yml文件(使用文档中的布局): 您的配置看起来不错,您是否也可以发布blog.html的相关部分以及其中一个博客文件的完整路径?该博客文件的内容也可能有用。@Rossblog.html文件的内容与中概述的内容完全

我第一次用Jekyll建立了一个网站,我一直在遵循Jekyll文档中列出的逐步教程。我已经按照中所述创建了帖子、布局和帖子列表(
blog.html
),但是当我在命令行中运行
jekyll-serve
时,我的帖子不会在
blog.html
中列出。这可能是什么原因

这是我的
\u config.yml
文件(使用文档中的布局):


您的配置看起来不错,您是否也可以发布
blog.html
的相关部分以及其中一个博客文件的完整路径?该博客文件的内容也可能有用。@Ross
blog.html
文件的内容与中概述的内容完全相同,并且位于根目录中。帖子位于
\u posts
目录中。@Ross仔细地梳理
\u config.yml
以查找任何错误,似乎
collections\u dir
语句在某种程度上阻碍了帖子的列表。我删除了它,它们现在显示在
blog.html
中。很好,只是给未来的读者一个提示,如果你有一个
collections\u dir
集,你的
\u posts
文件夹应该在里面。你的配置看起来不错,你能发布
blog.html
的相关部分和其中一个博客文件的完整路径吗?该博客文件的内容也可能有用。@Ross
blog.html
文件的内容与中概述的内容完全相同,并且位于根目录中。帖子位于
\u posts
目录中。@Ross仔细地梳理
\u config.yml
以查找任何错误,似乎
collections\u dir
语句在某种程度上阻碍了帖子的列表。我删除了它,它们现在显示在
blog.html
中。很好,只是给未来读者的一个提示,如果你有
collections\u dir
集,你的
\u posts
文件夹应该在里面。
# Where things are
source              : .
destination         : ./_site
collections_dir     : .
plugins_dir         : _plugins # takes an array of strings and loads plugins in that order
layouts_dir         : _layouts
data_dir            : _data
includes_dir        : _includes
sass:
  sass_dir: _sass
collections:
  posts:
    output          : true

# Handling Reading
safe                : false
include             : [".htaccess"]
exclude             : ["Gemfile", "Gemfile.lock", "node_modules", "vendor/bundle/", "vendor/cache/", "vendor/gems/", "vendor/ruby/"]
keep_files          : [".git", ".svn"]
encoding            : "utf-8"
markdown_ext        : "markdown,mkdown,mkdn,mkd,md"
strict_front_matter : false

# Filtering Content
show_drafts         : null
limit_posts         : 0
future              : true
unpublished         : false

# Plugins
whitelist           : []
plugins             : []

# Conversion
markdown            : kramdown
highlighter         : rouge
lsi                 : false
excerpt_separator   : "\n\n"
incremental         : false

# Serving
detach              : false
port                : 4000
host                : 127.0.0.1
baseurl             : "" # does not include hostname
show_dir_listing    : false

# Outputting
permalink           : date
paginate_path       : /page:num
timezone            : null

quiet               : false
verbose             : false
defaults            : []

liquid:
  error_mode        : warn
  strict_filters    : false
  strict_variables  : false

# Markdown Processors
kramdown:
  auto_ids          : true
  entity_output     : as_char
  toc_levels        : [1, 2, 3, 4, 5, 6]
  smart_quotes      : lsquo,rsquo,ldquo,rdquo
  input             : GFM
  hard_wrap         : false
  footnote_nr       : 1
  show_warnings     : false