This hugo website is my personal website.
- To create a new project:
hugo new projects/<page name>
- Build and run the docker image:
docker-compose build
docker-compose run app bash
- From the bash prompt, create a new hugo site in the current directory:
hugo new site . --force
-
Update the
config.toml
file with the settings for this website. -
Create a new theme:
hugo new theme <theme-name>
Good to go! Simply exit out of the container and bring the container up to start developing the site:
docker-compose up
Gosh, the documentation on this is hopeless... So, here it is in a nutshell.
-
In your theme folder, create
assets/scss/main.scss
. -
Wherever you want the uri for the compiled CSS, add the following:
{{ $sass := resources.Get "scss/main.scss" | resources.ToCSS (dict "outputStyle" "compressed") | fingerprint }}
<link rel="stylesheet" href="{{ $sass.Permalink }}">
- Build and tag:
docker build -t ejangi/hugo:latest .
- Push to docker hub:
docker push ejangi/hugo:latest