站点地图 (XML) 部分适用于 GitHub 页面,无法通过 Google Search Console 获取

Sitemap (XML) partially works on GitHub Pages and cannot be fetched by Google Search Console

我有一个网站,其自定义域托管在 GitHub 页面上。我已将站点地图文件添加到我的存储库,名称为 sitemap.xml。我可以通过转到 https://example.com/sitemap; however, https://example.com/sitemap.xml returns 404 错误来访问它。

此外,当我尝试将上述站点地图添加到 Google Search Console 时,它​​无法获取它。我已经尝试了两个网址,但均无效。

我没有使用 Jekyll 或任何其他框架。我能做什么?

.nojekyll 文件添加到我的存储库解决了这个问题。我猜想 GitHub Pages 假设我使用的是 Jekyll 并错误地编译了我的网站。