Creating an Online Documentation Website Part 3 - Hosting the Hugo website code on GitHub and using GitHub Pages specifically

In the previous two articles, we implemented real-time submission and update of GitHub local warehouse and remote warehouse, and deployed Hugo static page website. Next, we will host the Hugo website on GitHub and have its own online documentation website. Our local After modification, you can see the refreshed page in real time, and every change is recorded, and this website is free.

1. Configure GitHub Pages

1) On the GitHub web page, navigate to the remote repository.

2) Select Settings->Pages .

3) Under GitHub Pages, select the release source and its folder, and click Save .

Release source (Select branch)

Publish source folder (Select folder)

Here we select main as the publishing source and docs as the folder.

4) Select a website theme under Theme Chooser.

The page will refresh and the following URL will appear, which is the published URL.

2. Connect GitHub and Hugo

To be continued

Guess you like

Origin blog.csdn.net/qq_38250687/article/details/118515844