Getting started with Hugo for a personal blog:
Create a github repo for your content: with the name
<username>.github.io
Initialize the repo with Hugo using the quick start instructions here: https://gohugo.io/getting-started/quick-start/
Setup the repo to publish to the
gh-pages
branch using the Github workflow here: https://gohugo.io/hosting-and-deployment/hosting-on-github/Configure the actions-gh-pages deploy key as shown here: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-create-ssh-deploy-key
Now make sure to go back to the
Pages
section of your repo & set the branch togh-pages
, this will point the github action at your deploy branch.Finally, once the page is up and deploying successfully you can follow the instructions here to setup a custom domain with Namecheap: https://www.namecheap.com/support/knowledgebase/article.aspx/9645/2208/how-do-i-link-my-domain-to-github-pages/
- Enjoy