Welcome to WuJiGu Developer Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
544 views
in Technique[技术] by (71.8m points)

why is my hugo site not building on github pages?

So my hugo site is working on localhost and doesn't work on github pages.

My repo is at: https://github.com/ba789/ba789.github.io

question from:https://stackoverflow.com/questions/65648022/why-is-my-hugo-site-not-building-on-github-pages

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

You can follow the Hugo documentation "Host on GitHub", but you would need two different repositories:

As mentioned in the GitHub Pages documentation, you can host a user/organization page in addition to project pages.
Here are the key differences in GitHub Pages websites for Users and Organizations:

  • You must use a <USERNAME>.github.io to host your generated content
  • Content from the main branch will be used to publish your GitHub Pages site

This is a much simpler setup as your Hugo files and generated content are published into two different repositories.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to WuJiGu Developer Q&A Community for programmer and developer-Open, Learning and Share
...