【问题标题】:Hugo Site hosted in GitHub Pages. Main page shows ok but the Blog goes to 404Hugo 站点托管在 GitHub Pages 中。主页显示正常,但博客转到 404
【发布时间】:2021-01-25 07:31:08
【问题描述】:

我有一个托管在 GitHub Pages 上的网站: https://mcbridebr.github.io/mysite-hugo/

我已将其设置为从 master 分支的 docs/ 目录发布到页面。当我运行 hugo 时,它将发布到 docs/。

我可以调出主页就好了。但是当我点击博客时,它会转到 404。我有一篇博客文章在内容/帖子/下是空白的。如果我在本地运行它并使用 localhost:1313 访问它,则 BLOG 链接有效。我不确定这里发生了什么,任何建议将不胜感激。

源代码:https://github.com/mcbridebr/mysite-hugo

【问题讨论】:

标签: github-pages hugo


【解决方案1】:

我不得不返回并添加额外的布局 index.html 文件以适应博客部分。

【讨论】:

    猜你喜欢
    • 2018-11-08
    • 2019-10-30
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-08-02
    • 2021-07-12
    • 1970-01-01
    相关资源
    最近更新 更多