Yaml 如何获得_“第页”;在Jekyll中的站点根目录中引用?
我在GitHub页面上托管了Jekyll站点。文件Yaml 如何获得_“第页”;在Jekyll中的站点根目录中引用?,yaml,jekyll,Yaml,Jekyll,我在GitHub页面上托管了Jekyll站点。文件\u config.yml包含以下内容(摘录): 因此,当网站建立时,我可以通过其URL打开一个页面,如下所示: https://repo.github.io/_pages/some-page/ 我阅读了Jekyll的所有文档,但不清楚如何将此URL设置为https://repo.github.io/some-page/或者可能https://repo.github.io/pages/some-page/\u页面可被视为集合目录。 因此,只需具备
\u config.yml
包含以下内容(摘录):
因此,当网站建立时,我可以通过其URL打开一个页面,如下所示:
https://repo.github.io/_pages/some-page/
我阅读了Jekyll的所有文档,但不清楚如何将此URL设置为
https://repo.github.io/some-page/
或者可能https://repo.github.io/pages/some-page/
\u页面
可被视为集合
目录。
因此,只需具备以下配置:
collections:
pages:
output: true
将为您提供类似https://repo.github.io/pages/some-page.html
要获取自定义URL,您可以添加permalink
子配置:
collections:
pages:
output: true
permalink: /:collection/:path/
将为您提供类似https://repo.github.io/pages/some-page/
有关更多可能性,请参阅
collections:
pages:
output: true
permalink: /:collection/:path/