The easiest way to develop locally is using Docker, which automatically handles theme initialization:
Development mode serves drafts and auto-reloads on changes:
docker build -t kuberoke-hugo .
docker run --rm -it -v $(pwd):/src -p 1313:1313 kuberoke-hugoVisit http://localhost:1313 to see the site.
docker run --rm -v $(pwd):/src kuberoke-hugo --minifyThe built site will be in the public/ directory.
If you prefer to run Hugo directly on your machine:
-
Initialize theme (first time only):
git submodule update --init --recursive
-
Install Hugo: Follow instructions at https://gohugo.io/installation/
-
Run dev server:
hugo server -D -
Build:
hugo --minify
cd themes/blowfish
git checkout [VERSION/TAG/COMMIT]
cd ../..
git add themes/blowfish
git commit
- Create json file in
data/authors/, the filename is the author's key
{
"name": "Lian",
"image" : "img/avatars/lian.png",
"bio": "Chief Karaoke Officer",
"social": [
{ "twitter": "https://twitter.com/lianmakesthings" },
{ "mastodon": "https://hachyderm.io/@lianmakesthings"}
]
}
- Add key to event pages front matter
authors:
- "lian"-
Create event page
hugo new events/<event-slug>/index.md -
Add hero image as
events/<event-slug>/feature*