Making portfolio website with hugo and github pages

Making portfolio website with hugo and github pages

·

1 min read

First , you need to have hugo installed in your pc , follow the installation instructions given in hugo Documentation- gohugo.io/documentation .If you are using linux , you can run the command -

Sudo snap install hugo

Next , you need to install git and create a github account if you haven't already.

To host your personal website using github pages , follow the instruction given here- pages.github.com

I.e, first create a repository named username.github.io then clone the repository in your local machine .

Then go to hugo themes - themes.gohugo.io

Select a theme , i used Sada .Follow the Download instructions given over there.

For sada , I cloned the repository inside my username.github.io folder then removed the .git folder from it using rm -rf .git

Then change the directory git add . , git commit -m "portfolio website" then git push origin main

Then I follwed the instructions given over here - gohugo.io./hosting-and-deployment/hosting-o..

I made a hugo.yaml and copy-pasted the code. I had to make few changes in that - changed directory to sada before running hugo and also corrected the directory from which artefacts are uploaded - ./sada/public

Then after commiting the changes , the site became live.